What this tool does
Converts one signed integer into binary, octal, decimal, and hexadecimal representations without losing large-integer precision.
How to use it
- Choose the base of your input.
- Enter integer digits, optionally with a leading sign and matching 0b, 0o, or 0x prefix.
- Copy the output representation you need.
Worked example
Decimal 255 becomes binary 11111111, octal 377, and hexadecimal FF. Decimal -10 becomes hexadecimal -A.
Processing and explanation
Each digit contributes digit × base^position. The parser accumulates a BigInt, so integers above JavaScript’s Number safe-integer limit remain exact. Output uses a minus sign for negative numbers.
Limits and common mistakes
Up to 4,096 input characters. Fractions, digit separators, scientific notation, and fixed-width two’s complement are unsupported. The base is explicit: FF is hexadecimal, not a decimal input.
Privacy and your input
Text is read in this tab. This tool does not upload your text or include it in analytics; clearing the field removes the working input.
Frequently asked questions
- Does this decode binary text?
- No. It converts numeric values, not ASCII, UTF-8, or file bytes.
- Why does -1 not become FFFFFFFF?
- That form assumes a fixed bit width and two’s complement. This converter preserves a signed mathematical integer.
Material content update: