JSON Formatter
JSON Formatter for developers — instant, offline-style and privacy-safe.
Convert a number between binary, octal, decimal and hexadecimal — enter a value, pick its base, and see all four at once. Runs in your browser.
Your browser is preparing the tool. It runs 100% locally.
Enter a whole number and choose its base — binary, octal, decimal or hexadecimal — and the tool shows it in all four at once. It reads the value with the browser's integer parser, so a digit that is not valid for the chosen base stops the reading there. It handles whole numbers only, and very large values lose precision past the safe-integer limit. It runs entirely in your browser.
Type a number, tell the tool which base it is in (base 2, 8, 10 or 16), and you instantly see the binary, octal, decimal and hexadecimal forms together. It is the quick way to read a hex colour or memory address in decimal, or to see what a decimal value looks like in binary.
Hexadecimal output is shown in uppercase; the others in lowercase. The conversion is live, so editing the value or switching the input base updates all four readings at once.
The tool parses your input as an integer in the base you pick — using the browser's parseInt with that radix — then re-expresses that number in base 2, 8, 10 and 16. Because parseInt reads valid digits from the start and stops at the first character that is not valid for the base, a stray digit truncates the value rather than raising an error.
Only the first character being invalid produces a clear invalid-number message. Otherwise you always get a result, which is fast and forgiving but means you should check that your input contains only digits legal for its base — no 2 in a binary number, no letter G in a hex number.
decimal 255
binary 11111111
octal 377
hexadecimal FFEach base writes the same number with a different set of digits; base 16 uses 0-9 and A-F.
| Input bases | binary, octal, decimal, hexadecimal |
|---|---|
| Output | all four at once |
| Numbers | whole numbers only |
| Hex case | uppercase output |
| Invalid digits | reading stops at the first one |
| Large values | lose precision past the safe-integer limit |
| Where it runs | In your browser — nothing uploaded |
It parses leniently and stops at the first invalid digit. A binary input of 1012 is read as 101 (the 2 is not a binary digit), and a hex input of 1FG is read as 1F — no error, just a truncated value. Only an input whose very first character is invalid shows an invalid-number message.
It handles whole numbers only. There is no fractional or decimal-point support, so a value after a dot is dropped. For fractions you would need a tool built for non-integer base conversion.
Very large numbers lose precision. The browser represents integers exactly only up to 2 to the power 53 minus 1; beyond that, the result can be rounded silently, so this tool is reliable for ordinary values, not for huge ones where you would use arbitrary-precision arithmetic.
The input bases are limited to 2, 8, 10 and 16. It does not take other bases (such as base 3, 5 or 36) as input, though those four cover almost all everyday computing needs.
Hexadecimal is shown in uppercase and the others in lowercase. Hex is case-insensitive in value — FF and ff are the same number — but if a system you paste into expects one case, adjust accordingly.
See a hex colour, byte or address as a decimal number.
Check how a value looks across bases while coding or debugging.
See the same number written in binary, octal and hex side by side.
Translate a binary pattern into decimal or hexadecimal.
Need a base outside 2, 8, 10 and 16, or arbitrary precision? A programmer's calculator or a big-integer tool handles those. Doing bitwise math? A dedicated bitwise calculator shows the AND, OR and shift operations.
Reads the value with the browser's parseInt at the chosen base, so it stops at the first invalid digit rather than erroring; it is explicit that it handles whole numbers only, takes bases 2, 8, 10 and 16, and can lose precision past the safe-integer limit (2 to the power 53 minus 1).
JSON Formatter for developers — instant, offline-style and privacy-safe.
JSON Validator for developers — instant, offline-style and privacy-safe.
Base64 Encoder for developers — instant, offline-style and privacy-safe.
Fast, free Hash Generator that runs entirely client-side in your browser.
Fast, free UUID Generator that runs entirely client-side in your browser.
Fast, free CSS Minifier that runs entirely client-side in your browser.
It is free, private and runs entirely in your browser — no sign-up, no uploads, no limits.