Is there a way to convert BuiltinString or BuiltinByteString to String ?

There are these functions in the module PlutusTx.Builtins.Class

stringToBuiltinByteString :: String -> BuiltinByteString

stringToBuiltinString :: String -> BuiltinString

Are there functions to perform the inverse operation?

1 Answer 1


Yes, per the definition, BuiltinByteString derives Show, so you can write show bbs, where bbs is your variable, and it will convert your BuiltinByteString into a String

  • Thanks for pointing this out!
    – lambda
    Oct 13, 2021 at 14:07

Your Answer

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

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