Number Base Converter
Convert numbers between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16). Real-time, free.
Conversions
Enter a number above to see all base conversions.
Quick Reference
| Dec | Bin | Oct | Hex | Dec | Bin | Oct | Hex |
|---|---|---|---|---|---|---|---|
| 0 | 0000 | 0 | 0 | 8 | 1000 | 10 | 8 |
| 1 | 0001 | 1 | 1 | 9 | 1001 | 11 | 9 |
| 2 | 0010 | 2 | 2 | 10 | 1010 | 12 | A |
| 3 | 0011 | 3 | 3 | 11 | 1011 | 13 | B |
| 4 | 0100 | 4 | 4 | 12 | 1100 | 14 | C |
| 5 | 0101 | 5 | 5 | 13 | 1101 | 15 | D |
| 6 | 0110 | 6 | 6 | 14 | 1110 | 16 | E |
| 7 | 0111 | 7 | 7 | 15 | 1111 | 17 | F |
FAQ
What are number bases?
A number base (or radix) defines how many unique digits are used. Decimal uses 0-9 (base 10), binary uses 0-1 (base 2), octal uses 0-7 (base 8), and hexadecimal uses 0-9 and A-F (base 16).
Why do programmers use hexadecimal?
Hexadecimal is compact: one hex digit represents exactly 4 binary digits. This makes it easy to read memory addresses, color codes (#FF0000), and byte values. It's far more readable than long binary strings.
What is the 0x prefix?
0x is a common prefix to indicate a hexadecimal number (e.g., 0xFF = 255). Similarly, 0b indicates binary (0b1010 = 10) and 0o indicates octal (0o17 = 15). This tool accepts numbers with or without prefixes.
Does this support large numbers?
Yes. This tool uses BigInt for arbitrary-precision arithmetic, so you can convert numbers of any size without losing precision.
More Developer Tools You May Like
JSON Formatter
Format, beautify, minify and validate JSON with syntax highlighting.
CSS Minifier
Minify CSS to reduce file size or beautify minified CSS.
Text Case Converter
Convert text between camelCase, snake_case, kebab-case, and more.
Password Generator
Generate strong, random, cryptographically secure passwords.