BCD to Hexadecimal Converter
Convert BCD (Binary Coded Decimal) to hexadecimal online. Decodes BCD to decimal, then converts to hex.
Paste your BCD nibbles — either binary groups like 0100 1001 or packed hex pairs like 49 — and get the matching hexadecimal value back. Toggle between formats, switch the case, or add a 0x prefix on the way out. And everything runs in your browser. Nothing gets uploaded.
How to Use
Enter your BCD data in the left panel. Choose between Binary BCD (groups of 4 bits) or Packed BCD Hex format, or click Sample for example data.
Select your input format -- Binary BCD expects 4-bit binary nibbles, while Packed BCD Hex expects hex byte pairs where each nibble is a decimal digit (0-9).
Choose output options -- set the hex prefix (none or 0x) and letter case (uppercase or lowercase).
Copy, Download, or Swap the result. Swap moves the output to the input for further processing.
Frequently Asked Questions
What is BCD (Binary Coded Decimal)?
BCD is a way of encoding decimal numbers where each decimal digit (0-9) is represented by a fixed number of binary bits, typically 4 bits (a nibble). For example, the decimal number 49 is encoded as 0100 1001 in BCD -- the first nibble 0100 represents 4 and the second nibble 1001 represents 9. Unlike standard binary, BCD never uses bit patterns above 1001 (9) in a single nibble.
How does BCD to hexadecimal conversion work?
The conversion happens in two steps. First, the BCD input is decoded back to its decimal value -- each 4-bit group is read as a single decimal digit (0-9) and concatenated to form the full decimal number. Second, the resulting decimal number is converted to hexadecimal. For example, BCD 0100 1001 0010 decodes to decimal 492, which converts to hex 1EC.
What is the difference between Binary BCD and Packed BCD Hex?
Binary BCD input expects the raw 4-bit binary representations (e.g., "0100 1001" for 49). Packed BCD Hex input expects the same data written as hex byte pairs (e.g., "49" for 49). In packed BCD hex, each byte already looks like a decimal number because the hex digits 0-9 map directly to BCD nibbles. Both formats encode the same information, just in different notation.
What happens if I enter invalid BCD nibbles?
A valid BCD nibble can only represent decimal digits 0-9, which means the binary values 1010 through 1111 (hex A-F) are invalid in BCD. If your input contains any nibble with a value greater than 9, the tool will report an error. This is a key difference from standard hexadecimal, where all nibble values 0-F are valid.
Where is BCD commonly used?
BCD is widely used in financial and commercial applications where exact decimal representation matters, such as calculators, point-of-sale systems, and accounting software. It is also common in real-time clocks (RTCs), digital meters, embedded systems with 7-segment LED displays, and legacy mainframe computing (e.g., IBM COBOL packed decimal fields). BCD avoids floating-point rounding errors by preserving exact decimal values.