ToolSprinkle.

Number base converter

Convert exact integers between binary, octal, decimal and hexadecimal. Preserve large values, handle negatives and check valid digits locally.

From input to insight.
PROCESSED ON YOUR DEVICE

Ready when you are.

◎ No uploads. Your input stays here.↗ Free to use. No account needed.⌘ / Ctrl + Enter to run

A worked example

Using the default settings. You can try the same input in the workspace.

Input / settings

255

Expected result

FF
A LITTLE GUIDANCE

How to use Number base converter

Enter an integer without a base prefix, choose From and To, then select Run tool. A leading minus sign is accepted; output uses uppercase hexadecimal digits without prefixes or leading zeros.

Good to know

Uses BigInt for exact integers, up to 10,000 digits excluding a leading minus sign. No fractions, separators, explicit plus signs or fixed-width two’s-complement conversion.

A few quick answers.

Can I convert very large integers?

Yes. BigInt preserves integers exactly, with up to 10,000 digits excluding a leading minus sign. Choose the input base explicitly; fractions and prefixes such as 0x are not accepted.

Is my input sent to a server?

No. This tool processes your input in your browser. We don't store your text, files or results. Standard website access logs are separate; read our privacy notes.

Can I use it for free?

Yes. No account, subscription or usage credits are required.

How do I keep my result?

Use Copy or Download after running the tool. Inputs are not saved automatically and disappear when you leave or refresh the page.

Exact integers, digit rules and negative values

One value, four representations

Decimal 255 becomes binary 11111111, octal 377 or hexadecimal FF. Set From to Hexadecimal to convert ff back to decimal 255; hexadecimal input is case-insensitive. Leading zeros are not preserved: decimal 000255 also becomes FF.

Large IDs without Number rounding

Decimal 9007199254740993 converts to hexadecimal 20000000000001 and back exactly. The conversion accumulates digits using BigInt rather than JavaScript Number, so it does not lose precision above Number.MAX_SAFE_INTEGER. The input limit is 10,000 digits, not a promise of instant processing for every maximum-size value.

A minus sign is not a stored bit pattern

Decimal -255 converts to hexadecimal -FF or binary -11111111. This is signed mathematical notation, not an 8-, 16- or 32-bit two’s-complement representation. The tool does not choose a bit width, add padding, reinterpret bytes or change endianness. Negative zero normalizes to 0.

Reject digits that do not belong to the base

Binary accepts only 0 and 1; octal 0–7; decimal 0–9; hexadecimal 0–9 and A–F. Remove prefixes such as 0x, 0b or 0o and choose the base explicitly. Values such as 102 in binary, 1.5, +12, 1_000 and 1,000 are rejected. Outer whitespace is trimmed; spaces inside a number are not accepted.

Choose the representation you need: inspect a timestamp and its UTC instant, count calendar days or convert an integer’s base. Copy a value before switching tools; no input is transferred automatically. Base conversion changes notation, not timestamp units.

Method references: JavaScript Date, timestamps and UTC and BigInt exact integer arithmetic.

Keep your flow going.

More developer tools ↗

What would you like to do?

↑ ↓ Navigate · Enter Open · Esc Close. Switching tools clears unsaved input.