MultiSwitch MultiSwitch ← Home
SEARCH
SEARCH
← Home Feedback

Hex/Binary/Decimal Converter

Instantly convert between hexadecimal, binary, decimal, and octal

Hexadecimal
FF
Binary
11111111
Octal
377

Tip: You can enter numbers in any format. Hexadecimal can include "0x" prefix (e.g., 0xFF). Binary and Octal should be plain digits. Supports numbers up to 32-bit (0 to 4,294,967,295).

How this works: Whatever you type (decimal, 0x-hex, binary or octal) is parsed to one integer, then reprinted with toString(10/16/2/8). Invalid digits are ignored so the other fields do not update. This is integer conversion only — no two’s-complement width or IEEE floats.

How this works

Whatever you type into any field — decimal, 0x-prefixed hex, binary, or octal — is parsed into a single integer first, then reprinted in the other three bases using JavaScript's own toString(10/16/2/8) conversion, so all four fields always represent exactly the same number.

Invalid digits for the base you're typing in are simply ignored rather than throwing an error, so a stray character won't update the other fields until you've entered something that base can actually represent.

This is straightforward integer conversion — it doesn't model two's-complement bit widths (like 8-bit or 32-bit signed integers) or IEEE floating-point representations, so it's built for everyday base conversion, not for simulating how a specific programming language stores negative numbers or decimals in binary.

Acronyms on this page:
IEEE — Institute of Electrical and Electronics Engineers: the body behind the floating-point number standard this tool can convert to.

FAQ

Does this handle negative numbers?

It converts the integer value as entered, but it doesn't model two's-complement representation the way a specific programming language or CPU architecture would for negative binary numbers — treat it as plain integer base conversion.

What happens if I type an invalid character for the base I'm in?

It's ignored, and the other fields simply won't update until you've entered a value that base can actually represent — for example, typing '9' in the binary field won't register since binary only uses 0 and 1.

Does this support decimal (floating-point) numbers?

No — this converts whole integers between decimal, hexadecimal, binary, and octal. It doesn't handle fractional values or IEEE floating-point bit representations.

How do I enter a hex value — with or without the 0x prefix?

Either works — the converter parses standard 0x-prefixed hex notation as well as plain hex digits.