math hex to decimal javascript code example Example: convert hexadecimal to decimal js yourNumber = parseInt(hexString, 16);