StringToByteArray
StringToByteArray["string"] returns a byte array corresponding to the UTF-8 encoding of the specified string.
StringToByteArray["string","encoding"] uses the specified character encoding.
Please visit the official Wolfram Language Reference for more details and examples on core symbols.