Binary to Decimal Converter — Instant Base-2 to Base-10
Convert binary numbers to decimal instantly. Arbitrary precision, handles any bit-width. Free, runs in your browser — no ads, no signup.
Supports arbitrary-precision integers via BigInt — no 2⁵³ overflow. Handles negative numbers and the standard 0b/0o/0x prefixes. All conversion happens in your browser.
Converting binary to decimal, explained
Binary (base 2) is the native language of digital circuits — every number, every instruction, every byte of memory is ultimately a sequence of zeros and ones. Decimal (base 10) is what humans actually read. Converting binary to decimal means translating a bit string into the familiar base-10 form so you can compare it against human-written values or plug it into a calculation. This binary to decimal converter does the conversion instantly in your browser with arbitrary precision, so a 64-bit register dump is no harder to convert than a 4-bit nibble.
The conversion formula
To convert a binary number to decimal by hand, multiply each bit by the power of 2 matching its position (counting from the right, starting at 0), then sum the results. For example, converting binary 10110 to decimal:
1 × 2⁴ + 0 × 2³ + 1 × 2² + 1 × 2¹ + 0 × 2⁰ = 16 + 0 + 4 + 2 + 0 = 22
So binary 10110 equals decimal 22. The same method works for any bit string; the tool above automates it and handles arbitrary lengths correctly.
How to use this binary to decimal converter
- Type or paste a binary number (zeros and ones only) into the binary field.
- The decimal field updates live with the base-10 equivalent. Hexadecimal and octal also appear for reference.
- Spaces are tolerated between nibbles (groups of 4) —
1010 0110and10100110both convert to 166. - Non-binary characters surface an inline error so you know exactly which character is invalid.
Examples
Binary Decimal 0 0 1 1 1010 10 10000 16 11111111 255 # one byte max 100000000 256 1111111111111111 65535 # uint16 max 11111111111111111111111111111111 4294967295 # uint32 max
The tool uses JavaScript BigInt internally, so 65- or 128-bit binary strings convert exactly without precision loss.
When you actually need binary to decimal
- Reading a register dump or memory map. Hardware docs and emulator output often show values in binary. Converting to decimal lets you compare against human-written specs.
- Understanding bit flags. A permissions byte like
00000110decodes to decimal 6, which corresponds to "write + read" in Unix permissions. - Computing instruction opcodes. CPU instruction encodings are binary; converting to decimal helps when looking up a value in a table that uses decimal.
- Networking and subnet calculations. IP addresses, subnet masks, and wildcard bits are often reasoned about in binary but expressed in decimal dotted-quad form.
- Teaching and learning computer science. First courses in number systems always include binary-to-decimal drills.
Why binary is everywhere inside computers
Digital circuits have two stable states: high voltage and low voltage. Mapping those to 1 and 0 turns the hardware into a two-state (binary) computer. Everything else — integers, floats, text, images, instructions — is a layer on top of bit strings. Binary is the natural unit of computation; decimal is the natural unit of human reasoning. The conversion between the two is constantly happening at the boundary between your code and your eyes.
Common binary to decimal conversions
1 = 1 10 = 2 100 = 4 1000 = 8 10000 = 16 100000 = 32 1000000 = 64 10000000 = 128 11111111 = 255 # one full byte
Each additional zero to the right doubles the value — that is the essence of base-2 positional notation.
Privacy
This binary to decimal converter runs entirely in your browser. Conversion happens locally using JavaScript BigInt — no server, no request logs. Safe to paste any binary value you are debugging.
Frequently asked questions
Does the tool accept spaces in binary input?
Yes. Spaces are stripped before conversion, so 1100 1010 and 11001010 both convert to 202. This matches the convention of writing bytes with nibble-level spacing for readability.
Is there a maximum bit length?
No practical limit. The tool uses BigInt, so you can paste 256-bit values (a 256-character binary string) or larger without losing precision.
How do I convert a negative binary to decimal?
Binary itself is unsigned. Negative values are represented in two's complement at a fixed bit width: for 8-bit signed, 11111111 represents -1, not 255. This tool treats input as unsigned. For signed interpretation, compute value − 2^N where N is your bit width when the high bit is set.
How do I convert binary to decimal in code?
JavaScript: parseInt('10110', 2). Python: int('10110', 2). C: strtol(str, NULL, 2). All produce the same base-10 integer.
Why does the conversion result in such large numbers?
Binary is very inefficient in character count — 8 bits become 3 decimal digits at most, but 32 bits become up to 10 decimal digits. A 64-bit register value can reach 20 decimal digits. That growth is why hex is preferred over binary for longer values: each hex digit represents 4 bits, compressing the string length by 75%.
Related tools
- Number BaseConvert numbers between binary, octal, decimal, and hexadecimal instantly. Live bidirectional conversion with explanations — free, runs in your browser.
- Decimal to BinaryConvert decimal numbers to binary instantly. Arbitrary precision via BigInt, clean grouped output. Free, runs entirely in your browser.
- Binary to HexConvert binary numbers to hexadecimal instantly. Every 4 bits become one hex digit. Free, runs in your browser, arbitrary precision.