Skip to content
Converter Everyone Free Online Converters
Converter Everyone

Colour mode

↑↓ to choose Enter to open Esc to close

Number Base Converter

Convert numbers between binary, octal, decimal and hexadecimal (or any base from 2 to 36), and text to binary or hex.

Runs in your browser Free, no sign-up

What to convert

Base 10: 0–9

Base 2: 0 and 1

Base 16: 0–9, A–F

Base 8: 0–7

Any base from 2 to 36

How to use the number base converter

  1. Type a whole number in any box: decimal, binary, hexadecimal, octal, or a base of your choice from 2 to 36.
  2. All the other boxes update as you type. Prefixes such as 0x, 0b and 0o, and spaces or underscores between digits, are fine.
  3. For negative numbers, see the two’s complement form used by computers in 8, 16, 32 and 64 bits.
  4. Choose Text to turn words into binary or hex bytes, or paste binary or hex to read it as text.

Decimal, binary, octal and hex table

Numbers in four bases
DecimalBinaryHexOctal
0000
1111
21022
31133
410044
510155
711177
81000810
91001911
101010A12
121100C14
151111F17
16100001020
321000002040
64100000040100
100110010064144
12711111117F177
1281000000080200
25511111111FF377
256100000000100400
100011111010003E81750
1024100000000004002000
655351111111111111111FFFF177777

Frequently asked questions

How do I convert decimal to binary?

Divide the number by 2 again and again, writing down each remainder, then read the remainders from the last to the first. 13 ÷ 2 = 6 r 1, 6 ÷ 2 = 3 r 0, 3 ÷ 2 = 1 r 1, 1 ÷ 2 = 0 r 1, so 13 is 1101 in binary. The converter does this instantly for numbers of any length.

How do I convert binary to decimal?

Each binary digit is worth twice the one to its right: 1, 2, 4, 8, 16 and so on. Add up the values where there is a 1. For 1101 that is 8 + 4 + 0 + 1 = 13.

Why do programmers use hexadecimal?

One hex digit is exactly four binary digits, so a byte (8 bits) is always two hex digits, from 00 to FF. That makes long binary numbers, memory addresses and colours such as #FF8800 much shorter and easier to read.

How are negative numbers shown in binary?

Computers usually store them in two’s complement: flip every bit of the positive number and add 1. In 8 bits, −1 is 11111111 and −128 is 10000000. When you enter a negative number, the converter shows it in 8, 16, 32 and 64-bit two’s complement wherever it fits.

How does text to binary work?

Each character is turned into bytes using UTF-8, and each byte is written as 8 binary digits. "H" is 72, which is 01001000. Letters like é or emoji take two to four bytes. Paste binary or hex in the lower boxes to turn it back into text.

Is there a size limit?

Numbers can be up to 4,000 digits long; the converter uses exact whole-number arithmetic, so even very large numbers are converted without rounding. Fractions (numbers with a decimal point) are not supported.

Browse all tools