Embed this tool on your site
<iframe src="https://devtoolbox.dedyn.io/tools/number-base-converter" width="100%" height="600" frameborder="0" title="Number Base Converter"></iframe>

Number Base Converter

Convert numbers between binary, octal, decimal, and hexadecimal instantly. Supports any base from 2 to 36. All processing runs in your browser.

 

Common Values Reference Table

Quick reference for decimal values 0–255 in binary, octal, and hexadecimal.

Decimal Binary Octal Hexadecimal

About Number Bases

Binary (Base 2)

Binary uses only two digits: 0 and 1. It is the fundamental language of all digital computers and electronics. Every piece of data in a computer — text, images, instructions — is ultimately stored and processed as sequences of binary digits (bits). Binary is essential in low-level programming, hardware design, networking (subnet masks, IP addresses), and understanding bitwise operations.

Octal (Base 8)

Octal uses digits 0 through 7. Each octal digit maps to exactly three binary digits, making it a compact shorthand for binary. Octal is most commonly used in Unix/Linux file permissions (e.g., chmod 755), where read=4, write=2, execute=1 combine naturally in base 8. It also appears in some older computing contexts and escape sequences.

Decimal (Base 10)

Decimal is the standard human number system, using digits 0 through 9. It is the default representation in most programming languages and the system we use in everyday life. When you see a number without a prefix in code, it is decimal. Understanding how decimal relates to other bases is critical for debugging, memory analysis, and working with hardware registers.

Hexadecimal (Base 16)

Hexadecimal uses digits 0–9 and letters A–F (representing 10–15). Each hex digit maps to exactly four binary digits, making it the most popular compact representation of binary data. Hex is ubiquitous in programming: memory addresses (0x7FFE), color codes (#FF5733), MAC addresses, byte values, assembly language, and hex editors.

Custom Bases (2–36)

This tool supports any base from 2 to 36. Bases beyond 16 use letters of the alphabet for digit values above 9 (A=10, B=11, ... Z=35). Base 36 is sometimes used for compact URL-safe identifiers. Base 32 appears in some encoding schemes like Crockford's Base32. Understanding arbitrary bases is useful in computer science theory, cryptography, and specialized encoding systems.

Frequently Asked Questions

What are number bases?
A number base (or radix) determines how many digits are used to represent numbers. Decimal (base 10) uses 0-9, binary (base 2) uses 0-1, octal (base 8) uses 0-7, and hexadecimal (base 16) uses 0-9 and A-F.
Why do computers use binary?
Computers use binary because electronic circuits have two states: on (1) and off (0). All data — numbers, text, images, programs — is ultimately stored and processed as sequences of binary digits (bits). Higher bases like hex are shorthand for binary.
When do programmers use hexadecimal?
Hexadecimal is commonly used for memory addresses, color codes (#FF0000), byte values, MAC addresses, Unicode code points, and assembly language. Each hex digit represents exactly 4 binary bits, making it a compact way to express binary data.
Keyboard Shortcuts
Ctrl+Enter Run / Format
Ctrl+Shift+C Copy output
Ctrl+L Clear