Skip to content
EMV Tools

Tools

Hex, ASCII, decimal, binary, and BCD converter

EMV data and payment logs show the same value in different forms: hex bytes, ASCII text, decimal numbers, binary bits, or binary-coded decimal (BCD), where each hex digit is one decimal digit, as EMV does for amounts and dates.

Use it when a log prints a field in one form and a tool or a specification needs another, for example to read a cardholder name stored as hex or an amount stored as BCD.

Pick the format of your input and read it in every other format. Decimal values use exact integer arithmetic, so long numbers keep every digit.

Worked example: the card record example holds the cardholder name (5F20) as 544553542F43415244484F4C444552, which reads TEST/CARDHOLDER as ASCII. The amount 000000001000 from the terminal data example, read as BCD, is 1000 minor units: 10.00 in a currency with two decimals.

New to EMV? Read EMV in 5 minutes or browse the glossary

Everything runs in your browser. Nothing you enter leaves this page.

Input format

One byte, five ways to write it

One byte, five ways to write itThe byte 41 in hex written in every format: 0100 0001 in binary, 65 in decimal, the letter A in ASCII, and 41 when read as BCD, where each half-byte is one decimal digit.Hex41Binary0100 0001Decimal65ASCIIABCD41

Hex and BCD look alike but read differently. In hex, 41 is 4 × 16 + 1 = 65. In BCD, each half-byte holds one decimal digit, so 41 means forty-one.