Number Converters · Browser · Free
Hex to Binary Converter
Type a hexadecimal number and press Convert to view it in binary, decimal, and octal. A leading sign and a fractional point are accepted, a Swap button reverses the conversion, and lists of numbers are zero-padded to a common width.
What this tool converts
The tool takes a hexadecimal number (base 16) and converts it to binary (base 2). Decimal and octal equivalents are displayed alongside, giving you all major representations at once. Everything is entered into a single text field.
A leading sign and a fractional point are accepted. When you enter several numbers separated by whitespace, each value is converted and zero-padded to a common width of 8, 16, or 32 bits, keeping negative values unpadded. Letters in the result print in uppercase.
The form computes when Convert is pressed. The Swap conversion button reverses the conversion direction using your converted value. Copy writes the result to the clipboard, and Reset clears the form. Everything runs locally in your browser.
Hex to binary formula
Hexadecimal is base 16 and binary is base 2, and in both of them the place a digit sits in decides what that digit is worth. In hexadecimal each place is worth sixteen times the place to its right; in binary each place is worth twice the place to its right. A conversion simply spreads one amount over those places twice, once in each base.
The row 1F = 11111 in the table shows the method. On the hexadecimal side the 1 sits one place left of F, so it counts in units of sixteen while F fills the place at the right. On the binary side five digits cover places that double one after another, the leftmost being the sixteen place. Both strings of digits stand for the same amount, which is why they are listed together.
The row 64 = 1100100 is the same idea with some places left empty: those zeros mark places that carry nothing. Rows such as 8 = 1000 and 100 = 100000000 show the places at either end of a run, FF = 11111111 shows every binary place filled for two hexadecimal digits, and 0 = 0 shows the amount that leaves all of them empty.
| Hexadecimal (base 16) | Binary (base 2) |
|---|---|
| 0 | 0 |
| 1 | 1 |
| 2 | 10 |
| 3 | 11 |
| 7 | 111 |
| 8 | 1000 |
| A | 1010 |
| F | 1111 |
| 10 | 10000 |
| 1F | 11111 |
| 20 | 100000 |
| 40 | 1000000 |
| 64 | 1100100 |
| FF | 11111111 |
| 100 | 100000000 |
| 400 | 10000000000 |