Number Base Converter

Convert instantly between binary, octal, decimal, hexadecimal and any base from 2 to 36. See the result with proper prefix notation and bit representation.

number-base-converter.tool
Quick Examples
Enter a number above to see conversions.

Why Number Bases Matter in Programming

Computers work in binary (base 2) at the hardware level. Hexadecimal (base 16) is a convenient shorthand — one hex digit represents exactly 4 binary bits, making it easy to read memory addresses, colour codes and bitmasks. Octal (base 8) appears in Unix file permissions. Understanding how to move between these representations is a fundamental programming skill.

Reading Prefixes

Programming languages use standard prefixes: 0b for binary (0b1010), 0o for octal (0o12), and 0x for hexadecimal (0xFF). These tell the compiler or interpreter which base the literal is in. This tool displays the correct prefix for each output so you can paste directly into code.

Frequently Asked Questions

JavaScript handles safe integers up to 2^53 - 1 (9,007,199,254,740,991). For practical use in programming, most conversions involve 8-bit (0-255), 16-bit (0-65535) or 32-bit (0-4,294,967,295) values which are all well within range.
It is the standard prefix indicating the number is in base 16 (hexadecimal). 0b means binary (base 2) and 0o means octal (base 8). These prefixes are used in most programming languages including JavaScript, Python, C and Java.
Split the hex colour into three pairs: #FF8800 becomes FF, 88, and 00. Convert each pair separately. FF = 255, 88 = 136, 00 = 0 — so the RGB value is (255, 136, 0). The WTEC HEX to RGB tool handles colour conversions automatically.
Base 36 uses digits 0-9 and letters A-Z, giving 36 symbols. It produces very compact representations of large numbers and is used for URL shorteners, unique identifiers and anywhere you need a compact alphanumeric code. JavaScript's toString(36) and parseInt(str, 36) work with base 36 natively.
Because it maps cleanly to binary — one hex digit = 4 bits, two hex digits = one byte. A 32-bit memory address written as 0x0041F820 is immediately readable by experienced developers, while the same address in binary would be 32 characters long. Hex provides a compact, structured way to represent binary data.