Input

Output

Formatted result will be displayed here

What is a number base converter?

A number base converter translates an integer between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16). EasyRead detects the input base automatically from standard prefixes — 0b for binary, 0o for octal, 0x for hex — and shows every representation at once, so you can copy whichever one you need. It runs locally in your browser with no external calls.

Use Cases

Bitwise programming

Flip between binary and hex when working with flags, bitmasks, permission bits, or color channels.

Networking math

Convert IP octets, subnet masks, and CIDR blocks between binary and decimal while planning or debugging a network.

Embedded and driver work

Translate register values, memory addresses, and device IDs between hex and binary while reading datasheets.

Teaching computer science

Demonstrate how the same integer looks in each base when explaining data representation and bit-level operations.

FAQ

Which bases are supported?

Binary (0b prefix), octal (0o prefix), decimal (no prefix), and hexadecimal (0x prefix).

How is the input base detected?

By the standard prefix: 0b, 0o, or 0x. Bare digits are treated as decimal. You do not need to pick a base manually.

Are negative numbers supported?

Non-negative integers only for now. Use two's-complement representation if you need a negative number in a fixed-width binary or hex form.

How big can the number be?

Up to JavaScript's safe integer range, about 2^53 − 1. Larger values may lose precision.

Does the output include prefixes?

Yes. Each conversion includes its conventional prefix so the value is ready to paste into source code.