number theory calculators

Binary to Decimal Converter

Convert any binary (base-2) number to its decimal (base-10) equivalent in one click. Handy for programming, digital electronics, and computer science coursework.

About this calculator

Binary is a base-2 numeral system using only digits 0 and 1. To convert binary to decimal, each bit is multiplied by 2 raised to its positional power (counting from 0 on the right). Formally, decimal = Σ (bᵢ × 2^i) for each bit bᵢ at position i. For example, 1011₂ = 1×2³ + 0×2² + 1×2¹ + 1×2⁰ = 8 + 0 + 2 + 1 = 11₁₀. JavaScript's parseInt(binary, 2) performs this exact expansion internally. Binary is fundamental in computing because transistors represent two states — on (1) and off (0) — and all digital data is ultimately stored and processed in binary.

How to use

Enter the binary number 110101. The calculator runs parseInt('110101', 2). Working left to right: 1×2⁵ + 1×2⁴ + 0×2³ + 1×2² + 0×2¹ + 1×2⁰ = 32 + 16 + 0 + 4 + 0 + 1 = 53. So 110101₂ = 53₁₀. Type any sequence of 0s and 1s into the input field and the decimal result appears instantly — no manual positional expansion needed.

Frequently asked questions

How do you manually convert a binary number to decimal step by step?

Write out each binary digit and assign it a positional power of 2, starting at 0 from the rightmost bit. Multiply each digit (0 or 1) by its corresponding power of 2. Sum all the products to get the decimal value. For 10110: 1×16 + 0×8 + 1×4 + 1×2 + 0×1 = 22. Practicing this process builds intuition for how computers represent integers internally.

What is the largest binary number this converter can handle accurately?

JavaScript's parseInt function returns a standard 64-bit floating-point number, which safely represents integers up to 2⁵³ − 1 (about 9 quadrillion). Binary strings longer than 53 bits may lose precision due to floating-point limits. For cryptographic or arbitrary-precision work you would need a BigInt-based converter. For typical computing tasks — 8-bit bytes, 16-bit words, 32-bit integers — this converter is fully accurate.

Why do computers use binary instead of decimal internally?

Electronic circuits are most reliable when they distinguish just two voltage states: high (1) and low (0). Using more than two states introduces noise sensitivity and manufacturing complexity. Binary arithmetic maps perfectly onto logical operations (AND, OR, NOT) that are trivially implemented with transistors. This simplicity allows billions of transistors to operate reliably at gigahertz speeds. All higher-level data — text, images, audio — is ultimately encoded as sequences of binary digits at the hardware level.