OK, thanks.
The easiest ways if the messages are in the Messages app on the Mac are to have a Time Machine backup and/or simply print the messages to a PDF from the Messages app.
There are also third-party apps that can export and archive messages from the Mac. I am not sure about from iOS and the iPhone, as I don't have any experience with saving messages/texts.
Does that help at all?
C