Number Base Reference
- Binary (2): 0, 1
- Octal (8): 0–7
- Decimal (10): 0–9
- Hex (16): 0–9, A–F
- 255 decimal = FF hex = 11111111 binary = 377 octal
0x prefix and binary as plain 0s and 1s; the radix is set by the field, not by a prefix.9 in the octal field), an inline error appears and the other fields stop updating until the input is fixed.The converter is a thin wrapper around JavaScript's built-in parseInt(value, radix) for parsing and Number.prototype.toString(radix) for formatting, so the output matches the ECMAScript spec exactly. Hex output is uppercased for visual clarity, and the value stays as a JavaScript Number — accurate up to 253 − 1 (9,007,199,254,740,991). Beyond that, precision is lost and a BigInt-based tool is needed.
It is well-suited to everyday programming tasks: decoding hex colour codes, reading byte values from a hex dump, checking permission bits in octal, or sanity-checking a binary literal from a CPU manual. It is not intended for two's-complement work — negative numbers are written with a leading minus rather than as a two's-complement bit pattern — and it is not arbitrary precision, so cryptographic-sized integers should be converted with a BigInt tool instead.
parseInt / toString(radix) — no custom math, matches the JS specBase 32 is used in RFC 4648 and Crockford encodings (and by some MAC-address shorteners); base 36 (0–9 + a–z) is the densest alphanumeric encoding using only ASCII letters and digits, so it is common in short URLs and database IDs.
Up to JavaScript's safe-integer limit of 253 − 1 (9,007,199,254,740,991). Above that, parseInt loses precision; use a BigInt-based tool for arbitrary-size integers.
parseInt accepts a leading minus sign in any base, but toString writes a leading minus rather than a two's-complement representation. If you need two's complement (e.g. for low-level binary work), inspect a Bitwise Calculator instead.
The hex input field tells parseInt the radix directly, so prefixes are not stripped automatically. Type FF, not 0xFF, when entering into the Hexadecimal field.
Explore the full suite of MATH tools and 290+ other free utilities at Chunky Munster.