Number Base Converter
Binary, octal, decimal, hex and any base 2–36
One asymmetry is worth stating up front: this converter will read a number written in any base from 2 to 36, but it only ever writes the answer in four of them — binary, octal, decimal and hexadecimal. Those are the four that turn up in code, and a value you type in base 7 or base 36 is accepted as input and reported in the other four. Parsing is strict about the digits you supply: a digit that does not exist in the chosen base, a leading minus sign or a decimal point all cause the result to be rejected rather than silently misread. The conventional 0x, 0b and 0o prefixes are stripped when they match the base you selected, and stray whitespace is ignored. Integers only, up to the exact range of a double, which is 9007199254740991.
Convert numbers between decimal, binary, octal, hexadecimal and any base from 2 to 36. Includes bit grouping and quick presets — the everyday companion for programmers.
Private Number Base Converter In Your Browser
Number Base Converter is processed locally with client-side JavaScript. Your files never touch a server, and there is no queue to wait in.
How to use Number Base Converter
Enter the number in the Number field, using the digits valid for the base you intend.
Choose the base it is written in from the Input base dropdown, or click the bin, oct, dec or hex shortcut beside it.
Read the four result cards, each with its own copy button, and note that hexadecimal is shown in capitals.
Use the All at once panel when you want the four values together as labelled lines in one block.
- Input accepted in any base from 2 to 36, with letters a to z as digits above 10
- Output shown in binary, octal, decimal and hexadecimal, each individually copyable
- 0x, 0b and 0o prefixes handled automatically for their matching bases
- Invalid digits, negatives, decimals and out-of-range values rejected with an explanation
- A developer reading a hex colour constant and needing its decimal and binary forms side by side.
- A systems student working through an octal file permission such as 755 and checking the equivalent bit pattern.
- A database engineer inspecting an identifier stored as 0x1F4 and confirming it is the decimal 500 it should be.