I can't find much documentation on this, is it possible to encrypt/decrypt data within a tezos smart contract? So how would I do something like AES crypto (although does not matter much) in a smart contract?

2 Answers 2


There are currently no encrypt/decrypt instructions for Michelson. You can view the full list of instructions here: http://tezos.gitlab.io/mainnet/whitedoc/michelson.html


It's not clear what decrypting data from within a smart contract would achieve since all operations are public.

  • obviously all transactions and data is public, encryption in a smart contract could be used to implement something like a vickery auction (en.wikipedia.org/wiki/Vickrey_auction) - all bidders send in their bid during bid period, bids only get known to public after bid period is over. btw this is not an answer this should have been a comment.
    – joschua011
    Commented Feb 3, 2019 at 17:41
  • 1
    You can do that with hash commitments, no need for encryption
    – Arthur B
    Commented Feb 3, 2019 at 18:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.