4,056 questions
4,264 answers
5,547 comments
Yes, OP_RETURN is the correct way to store arbitrary data in a blockchain transaction. You can use APIs like sendwithmetadata or appendrawmetadata to make it easier to build transactions with OP_RETURN.