Number Base Converter
Type a number in any base and instantly see all other representations. Supports binary, octal, decimal, hex, and more.
How to use Number Base Converter
The number base converter translates integers between binary (base 2), octal (base 8), decimal (base 10) and hexadecimal (base 16) number systems. Type in any base and all other bases update simultaneously. Negative numbers are shown in two's complement representation. Useful for programming, computer science and digital electronics work.
- Enter a number in any base field: binary, octal, decimal or hexadecimal.
- All other base representations update instantly.
- Toggle signed/unsigned mode to see two's complement for negative values.
- Copy any output with the copy button.
Your data never leaves your device — 100% private processing.
How different number bases work
Decimal (base 10) uses digits 0–9. Binary (base 2) uses only 0 and 1 — the native language of digital computers. Octal (base 8) uses digits 0–7 and was historically used in Unix file permissions. Hexadecimal (base 16) uses 0–9 and A–F; each hex digit represents exactly 4 binary bits, making it a compact shorthand for binary used in memory addresses, colour codes (#RRGGBB) and cryptographic hashes.
| Decimal | Binary | Octal | Hexadecimal |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 10 | 1010 | 12 | A |
| 255 | 11111111 | 377 | FF |
| 1024 | 10000000000 | 2000 | 400 |
Two's complement for negative numbers
Computers store negative integers using two's complement. For an n-bit integer, the two's complement of a negative number N is 2ⁿ − |N|. For −1 in 8 bits: 256 − 1 = 255 = 11111111₂. This system has the advantage that the same hardware circuits handle both addition and subtraction. The most significant bit (leftmost) is the sign bit; 0 = positive, 1 = negative.
Glossary
- Binary
- Base-2 number system using digits 0 and 1.
- Hexadecimal
- Base-16 number system using digits 0–9 and letters A–F.
- Two's complement
- A method of representing negative integers in binary, used universally in computing.
- Octal
- Base-8 number system using digits 0–7, historically used in Unix file permissions.
Related reading
Frequently Asked Questions
Get weekly tool tips & updates
New tools, power-user tips, and productivity hacks — delivered free every Friday.
No spam, ever. Unsubscribe with one click.
Why use Number Base Converter?
- Real-time unit conversion with live preview
- Covers hundreds of unit types in one place
- High-precision results with up to 10 decimal places
- No need to memorise formulas — just type and convert
Common use cases
- Convert recipe measurements from cups to grams
- Calculate fuel economy in miles per gallon vs litres per 100km
- Convert temperatures for international travel
- Convert dimensions between metric and imperial for DIY projects
- Calculate distance conversions for running or cycling plans
Related Converters
Hash Generator
Generate MD5, SHA-1, SHA-256, SHA-384, and SHA-512 hashes online. Hash text or files privately in your browser.
Base64 Encoder & Decoder
Encode text or files to Base64, or decode Base64 strings back to text. Fast, free, and runs entirely in your browser.
JSON Formatter & Validator
Format, validate, and minify JSON instantly. Includes syntax highlighting, error detection, and a collapsible tree view — free, private, in-browser.
Unit Converter
Convert units of length, weight, temperature, volume, speed, area, and data. A fast, free online unit converter with instant, accurate results.
Color Format Converter
Convert colors between HEX, RGB, HSL, HSV, and CMYK formats. Paste any color format and get all others instantly. Free online color converter.
Currency Converter
Convert between 35+ world currencies with reference exchange rates. See USD, EUR, GBP, JPY, INR, and more. Free online currency calculator.
Explore all Converters.