Number Base Converter Online — Free Tool

Seamlessly convert numbers between Binary, Octal, Decimal, and Hexadecimal representations.

Supports optional prefixes: 0x, 0b, 0o.
Decimal
255
Binary
0b11111111
Octal
0o377
Hex
0xFF
Privacy note: All processing happens entirely in your browser. No data is sent to our servers.

About this tool

Binary, octal, decimal, and hexadecimal are common in programming and networking. Convert a number between bases instantly without mental arithmetic.

Enter a value in one base and see equivalents—useful for flags, color hex, and low-level debugging.

Common use cases

  • Converting hex color channels to decimal
  • Reading memory addresses and bitmask flags
  • CS homework and certification study
  • Debugging protocol fields in packet captures

How to use

  1. Select source base or input format.
  2. Enter the number using valid digits for that base.
  3. Read converted values in all supported bases.
  4. Copy the representation you need for code or docs.

This page is available at /tools/number-base-converter/.

Understanding the result

  • Invalid digits for a base (e.g. 8 in octal) should error or reject input.
  • Large integers may lose precision in JavaScript above Number.MAX_SAFE_INTEGER—watch 64-bit values.
  • Hex often uses 0x prefix in code; tool output may omit prefix for copy-paste flexibility.
  • Negative numbers need two's complement awareness in fixed-width contexts.

FAQ

How do I convert binary to decimal?

Each bit is a power of two. The tool automates positional sum for any length.

What is 0x prefix?

C-style hex literal marker. Decimal 255 is 0xFF in hex.

Floating point bases?

This tool targets integers. Fractional base conversion is a separate problem.

Big integers?

Very large values may need BigInt-aware tools beyond standard JS number.