Skip to main content

Hex Converter

Convert between hexadecimal, decimal, binary, and octal number systems.

hexbinaryoctaldecimal
Read the guide
Shortcuts:⌘ KSearch

Enter a value in any base and all others will update instantly.

Frequently Asked Questions

Why did my other fields clear when I typed one bad value?

The converter uses the field's base to parse your input immediately. If that parse fails, it clears the other outputs and shows "Invalid value for base X" instead of guessing.

Can I paste spaces into binary or hex values?

Yes. The tool strips whitespace before parsing, so values like `1111 0000` or `DE AD BE EF` still convert correctly.

What does the 'Negative (two's complement 32-bit)' line mean?

That line shows the same number forced into a signed 32-bit JavaScript integer with `n | 0`. It's useful for checking how a value would look if interpreted as a 32-bit signed number.

Why did `15.9` turn into `15`?

This tool uses `parseInt`, so it is strictly integer-based. Anything after a decimal point is ignored rather than converted as a fraction.

Do I need prefixes like `0x` or `0b` here?

Usually no. Each input box already defines the base, so the safest input is plain digits for that base, like `ff` in hex or `1010` in binary.

Related Tools