--- title: toAscii description: "Converts a hexadecimal string into its corresponding ASCII string value." keywords: ["toascii", "utils", "hex to ascii", "decode hex", "tronweb"] --- # toAscii Convert HEX string to ASCII string. ### Usage ```JavaScript TronWeb.toAscii(value); ``` ### Parameters | Parameter | Description | Data Type | | --------- | -------------------- | --------- | | value | A hexadecimal string | String | ### Returns String - The ASCII value corresponding to the given hexadecimal string. ### Example ```JavaScript const str = tronWeb.toAscii("0x74726f6e") // output-start 'tron' // output-end ```