Number Base Converter — Binary, Octal, Decimal, Hex
Convert instantly between binary, octal, decimal and hexadecimal. Type a value into any of the four fields and the other three update automatically. Everything runs in your browser — nothing is ever sent anywhere.
Supports numbers up to 200 digits in each base.
Your input is processed entirely in your browser and is never sent anywhere.
How to use
- Type a number into any one of the four fields (binary, octal, decimal or hexadecimal).
- The other three fields update automatically with the converted value — no button needed.
- Use the copy button to copy a result, or "Clear" to reset every field.
How it works
How the conversion works
Type a value into any one of the four fields (binary, octal, decimal, hexadecimal) and the other three are converted and shown in real time. Internally, the entered value is parsed as an integer in the source base, then rendered in each of the four bases.
Hexadecimal letters can be entered in upper or lower case; results are always shown in upper case (A–F).
Negative numbers
A single leading - is accepted for negative numbers. Negative values are handled using sign-and-magnitude notation, not two's complement. For example, decimal -10 becomes -1010 in binary and -A in hexadecimal. Two's complement (a fixed bit-width bit-pattern representation) is not supported, since it would require choosing a bit width up front and adds complexity beyond what a general-purpose converter needs.
Decimal points
Only integers are supported. Values with a decimal point cannot be entered.
Precision
JavaScript's ordinary Number type loses precision above 2^53-1 (9,007,199,254,740,991). This tool uses BigInt (arbitrary-precision integers) internally, so values beyond that boundary still convert exactly, with no rounding error.
Maximum length
Each field accepts up to 200 digits. Extremely long input is rejected to avoid excessive processing load.
What data is sent
All conversion happens entirely in your browser. Nothing you type — including the numbers themselves — is ever sent to a server.
FAQ
Is the number I enter sent anywhere?
No. All conversion happens entirely inside your browser, and nothing is transmitted to any server or external API.
How are negative numbers converted?
Enter a leading "-" and the value is converted using sign-and-magnitude notation. For example, decimal -10 becomes -1010 in binary and -A in hexadecimal. Fixed-width two's complement representations (like 8-bit or 16-bit) are not supported.
Can I enter hex digits in lower case?
Yes. Entering a-f or A-F both work and produce the same result; the output is always shown in upper case (A-F).
Does it handle very large numbers accurately?
Yes. JavaScript's ordinary number type loses precision above 2^53, but this tool calculates using BigInt (arbitrary-precision integers), so values up to 200 digits convert exactly with no loss of precision.
Can I convert numbers with a decimal point?
No, this tool only supports integers.
Related tools
- Base64 Converter — Encode & Decode TextEncode text to Base64, or decode Base64 back to text — with correct handling of emoji and other multi-byte UTF-8 characters. Supports the URL-safe variant for JWTs and URL parameters. Everything runs in your browser; nothing is ever sent anywhere.
- CSV Column EditorExtract, reorder and merge CSV columns. Combine "First name" and "Last name" into a single "Full name" column, or reshape a contact list before importing it elsewhere. Everything runs in your browser — your data is never sent anywhere.
- CSV ⇔ JSON ConverterConvert between CSV and JSON in either direction. Use dot notation in column headers (like user.name) to represent nested objects and arrays. Everything runs in your browser — your data is never sent anywhere.
- JWT Decoder | View Header & Payload in Your Browser (No Signature Verification)Paste a JWT (JSON Web Token) to instantly decode and view its header and payload. This tool does not verify signatures. Everything runs in your browser only — your token is never sent anywhere.
- All tools