This tool runs entirely in your browser. Nothing you paste is uploaded.
How you can check →Number Base Converter
Numbers & BitsAny base, any size, with the width and sign stated out loud — and the fractional half done exactly, so it tells you whether your number terminates in that base or repeats forever.
Type or paste a value above to convert it, live, in every base.
Width
Bits
Division / remainder steps
| Dividend | ÷ base | Quotient | Remainder | Digit |
|---|
Digit place-value table
| Position | Digit | Place value | Contribution |
|---|
Equivalent code
Need bitwise operations instead — AND, OR, XOR, shifts? See the bitwise calculator.
No network activity while you use this tool Show the numbers
- Requests to any other server
- 0
- Requests since you started typing
- —
- Same-origin requests
- 0
Counted live by your browser's own Performance Timeline — the same data the DevTools Network panel reads. It cannot see what a browser extension does, and it is not meant to replace checking for yourself: here is how, in thirty seconds .
What a base is, and why 2, 8, 10 and 16 won
A number base (or radix) is just the count of distinct digits before a position rolls over to the next column — ten digits for decimal, two for binary. Any integer 2 through 36 works the same way; the digit alphabet here is 0-9 then a-z, so 36 is the practical ceiling before running out of agreed single characters. Binary and hex won because they map cleanly onto how a computer stores bits (each hex digit is exactly four bits); octal survives mostly in Unix file permissions, where three digits map onto three permission groups.
parseInt is wrong above 2^53, silently
parseInt("FFFFFFFFFFFFFFFF", 16) returns 18446744073709552000. The
true value is 18446744073709551615 — off by 385, with no error and no warning,
because JavaScript numbers only carry 53 bits of integer precision exactly. Any converter
built on parseInt is confidently wrong on every 64-bit value pasted into it,
which is most of what a developer actually converts. This tool runs on BigInt throughout, so
arbitrarily large integers stay exact.
Why -5 in hex has three different answers
Two's complement means nothing without a width: -5 is fb at 8 bits,
fffffffb at 32 bits, and fffffffffffffffb at 64 bits. A tool that
answers "what is -5 in hex?" with just one of those has answered a question you didn't ask.
The width strip on this page is deliberately visible and defaults to no fixed width at all
(arbitrary precision) — pick one to see the two's-complement bit pattern, and this tool shows
both the unsigned and signed reading of the same bits side by side, labelled.
The terminating-expansion rule
A fraction in lowest terms has a finite expansion in base b exactly when every prime factor of its denominator divides b. One tenth terminates in base 10 (factors 2 and 5, both divide 10) and in base 20, but never in base 2 or base 16 (5 never divides a power of 2). When an expansion doesn't terminate, its period length is computable exactly — this tool derives both facts from the denominator's factorisation rather than from running out of digits, so it can tell you a fraction repeats even before printing a single digit of it.
The base-32 name collision
Radix 32 and RFC 4648 Base32 are unrelated ideas that happen to share a name. Radix 32 is a
positional number system, digits 0-9a-v. RFC 4648 Base32 is a byte encoding with
a fixed alphabet (A-Z2-7) and = padding — it encodes arbitrary
bytes, not a number's numeric value. This converter only ever offers radices; for the RFC 4648
encodings, use the Base64 encoder.
What a leading zero means in which language
0755 is 493 in C, Go, Perl and Python 2 (legacy octal), and
755 in Python 3, strict-mode JavaScript, and most calculators. Neither reading is
wrong; picking one silently is. This tool detects the shape and asks which reading you meant
rather than guessing.
Common use cases
- Converting a 64-bit hex value or bitmask without precision loss
- Checking whether a negative number's hex form depends on width or signedness
- Understanding why a fraction like 0.1 never terminates in binary
- Reading an unfamiliar literal syntax — Verilog, Ada, Lisp, Pascal, Intel assembly
- Generating the equivalent conversion code in another language
Frequently asked questions
- Why is my 64-bit hex value wrong on other converters?
- Most web converters use JavaScript's parseInt, which silently loses precision past 2^53: parseInt("FFFFFFFFFFFFFFFF", 16) returns 18446744073709552000, not the true 18446744073709551615 — off by 385, with no warning. This tool runs on BigInt throughout, so arbitrarily large integers convert exactly.
- Is 0xFFFFFFFF equal to 4294967295 or -1?
- Both, depending on how you read the same 32 bits: 4294967295 unsigned, or -1 as a two's-complement signed 32-bit integer. Neither answer is more correct than the other — the question is which one you meant, which is why this tool shows both, labelled, the moment a width is set.
- Does 0.1 terminate in binary?
- No — 1/10 never terminates in base 2 or base 16, only in bases whose prime factors cover 10's factors (2 and 5), such as base 10 or base 20. This tool computes the terminating-or-repeating verdict from the fraction's factorisation, not by running out of digits, and states the period length when it repeats.
- What does a leading zero mean, like 0755?
- It depends on the language: 0755 is 493 in C, Go, Perl and Python 2 (legacy octal), and 755 in Python 3, strict-mode JavaScript, and most calculators. This tool detects the ambiguity and asks you to pick a reading rather than silently choosing one.
- What's the difference between radix 32 and Base32?
- Different things that share a name. Radix 32 is a positional number system using digits 0-9a-v. RFC 4648 Base32 is a byte encoding with a fixed alphabet (A-Z2-7) and padding — it encodes bytes, not a number's value. This converter only offers radices; use the Base64 encoder for the RFC 4648 encodings.
- Does converting a number here upload anything?
- No. Every conversion runs in this tab's JavaScript; nothing you type is sent anywhere. The privacy receipt below the tool measures the actual network requests from this page load, so the claim is checkable rather than asserted.
Explore more tools
AND, OR, XOR, NOT and shifts at any width up to 64-bit and beyond, with a per-bit diagram and a shift receipt.
Decimal, hex or binary in — sign, exponent and mantissa out, with the exact stored value and the rounding error against what you typed.
Encode text to base64 or decode base64 back to text.