Encoding desk

Binary to Decimal

Convert a signed binary integer to decimal using exact BigInt arithmetic.

Binary to Decimal: Read a base-2 integer as an ordinary decimal value. Binary to Decimal adds the powers of two represented by its digits and accepts an explicit plus or minus sign. It helps interpret bit flags or check a binary worksheet without guessing a storage width or a signed machine format. Runs 100% locally in your browser with zero server file uploads.

Runs
In your browser
Cost
Free · no sign-up
Availability
Ready to use
Binary → Decimal / local workbenchLocal processing

Runs entirely in your browser

256 character input · 1,024 character output

Result

Ready

Conversions run locally. Numeric values are integers, signs are normalized, and prefixes such as 0b or 0o are intentionally not accepted.

Positional formula with a complete sum

For bits b_i at positions i counted from zero on the right, magnitude N = sum of b_i × 2^i. Apply an explicit minus sign after the sum. For 110101, the set bits have weights 32, 16, 4 and 1, so N = 1×32 + 1×16 + 0×8 + 1×4 + 0×2 + 1×1 = 53. Entering those six digits returns 53. These are ordinary binary places; four-bit BCD groups would encode separate decimal digits and are not decoded here.

Storage width and precision boundaries

For a signed w-bit two’s-complement source with its top bit set, signed value = unsigned value − 2^w; Cornell’s explanation (https://www.cs.cornell.edu/~tomf/notes/cps104/twoscomp.html) describes this representation. The input accepts at most 256 characters including its sign, with a 1,024-character result limit. There is no 32-bit or 64-bit wraparound. JavaScript’s safe integer range ends at 2^53 − 1 = 9,007,199,254,740,991 (https://tc39.es/ecma262/multipage/numbers-and-dates.html#sec-number.max_safe_integer), so keep larger exported values as text or exact integers. Use hex to decimal if the same integer is supplied in hexadecimal notation.

How to use it

  1. Enter the value in the format shown below.
  2. Run the conversion and check the result against your source convention.
  3. Copy or download the output in the form required by your destination.

Privacy & limitations

Conversion runs in your browser. Your values and results are not uploaded.

Related tools

Frequently asked questions

Does a leading 1 make my binary number negative?

No. Without a minus sign, all digits describe a positive magnitude. The eight-bit pattern 11111011 converts to 251. If your source specifies signed eight-bit two’s complement, interpret that result separately as 251 − 256 = −5. The tool has no bit-width selector.

Can I paste grouped bits or a 0b prefix?

Enter continuous digits 0 and 1, optionally preceded by one sign. Spaces, underscores, 0b prefixes and fractional points are rejected. Leading zeros are accepted but have no effect on the value. The binary position sequence is read from left to right as written, without reversing bytes.

Is a long binary value rounded to a JavaScript number?

The conversion uses exact integer arithmetic and returns decimal text. It does not first coerce your digits to a floating-point Number. Precision can still be lost later if you paste a large result into software that treats it as a Number or a spreadsheet numeric cell.

Free tool · runs in your browser · no account required