Decimal to single and double precision bits, sign exponent mantissa split, full hex and binary, all in your browser
- Runs locally
- Category Developer & DevOps
- Best for Formatting, validating, shrinking, or inspecting code-adjacent text.
IEEE 754 Floating Point
value = (−1)^sign × 1.mantissa × 2^(exp − bias)
Everything runs on ArrayBuffer in your browser — the same encoding the CPU uses. Nothing is uploaded.
What this tool does
A precise IEEE 754 floating point converter for developers and CS students. Type a decimal value and see exactly how the CPU stores it: the single (32-bit) or double (64-bit) layout broken into its sign bit, exponent field and mantissa, plus the complete hex word and the full binary string. Go the other way too. Paste a hex or binary bit pattern and the tool decodes it back to the decimal value it represents. Every conversion runs on a real ArrayBuffer and DataView, the same encoding path the hardware uses, so 0.15625 lands on 0x3E200000 and 0.1 shows its true repeating mantissa rather than a rounded approximation. Special values are labelled clearly: positive and negative zero, infinity, NaN and subnormal (denormal) numbers each get their own class badge, with the biased exponent and the real exponent both shown. One-click copy for hex, binary and the decoded value. The decimal input and precision are saved in the URL so a shared link reopens the exact same number.
Tool details
- Input
- Numbers
- The page exposes text boxes, numeric controls, file pickers, or structured inputs depending on the tool.
- Output
- Live result + Copy
- The result area focuses on usable output, with copy, download, or preview actions when supported.
- Privacy
- Browser-side processing
- The main tool logic does not call an external API, so inputs normally stay in the current tab.
- Save / share
- Shareable URL state
- Key settings are encoded in the URL so another person can reopen the same setup.
- Performance budget
- Initial JS <= 9 KB
- No WASM budget is declared, keeping the tool quick to open on mobile.
- Best fit
- Developer & DevOps · Developer
- Category and role tags drive related tools, internal links, and quick fit checks.
How to use
-
1. Input
Paste or drop your content into the tool panel.
-
2. Process
Click the button. All processing is local in your browser.
-
3. Copy / Download
Copy the result or download to disk in one click.
How IEEE 754 Floating Point Converter fits into your work
Use it in the small gaps between coding, reviewing, debugging, and shipping.
Developer jobs
- Formatting, validating, shrinking, or inspecting code-adjacent text.
- Preparing snippets for documentation, tickets, commits, or handoff.
- Checking a small payload quickly without switching tools.
Developer checks
- Run irreversible transforms like minify or obfuscate on a copy.
- Keep secrets out of pasted snippets unless the tool explicitly stays local.
- Use your normal tests or linter before shipping transformed code.
Good next steps
These links move the current task into a more complete workflow.
- 1 Number Base Converter Number base converter — binary, octal, decimal, hex, and any base 2-36. Bitwise too. Open
- 2 Bitwise Calculator AND, OR, XOR, NOT and bit shifts on integers, with decimal, hex and binary side by side, all in your browser Open
- 3 Scientific Calculator Scientific calculator — sin / cos / log / sqrt / power, with full keyboard input + history, deg/rad mode. Open
Real-world use cases
Debug a floating point mismatch in code
Your test asserts 0.1 + 0.2 === 0.3 and it fails. Paste 0.1, then 0.2, then 0.3 in double precision and read the mantissas side by side. You will see that the stored bits for 0.1 + 0.2 differ from the stored bits for 0.3 by one unit in the last place, which is exactly why the equality breaks and why you should compare with an epsilon instead.
Understand a raw value from a memory dump or packet
A binary protocol hands you four bytes, 0x42 0x28 0x00 0x00, that are supposed to be a float. Concatenate them to 0x42280000, drop it into the bit-pattern field in single precision, and the tool decodes it to 42.0. No more squinting at a hex editor and doing the exponent math by hand.
Teach or learn how floats really work
A CS lecturer can show 1.0 as 0x3F800000, then 2.0, then 0.5, and let students watch only the exponent change while the mantissa stays zero. Toggle to double precision and the same numbers reappear with an 11-bit exponent. The colored bit strip makes the three fields obvious without drawing them on a whiteboard.
Verify a hand-written float encoder or decoder
Writing serialization for an embedded target without a standard library? Encode a handful of values in your own code, then check each one against this tool. If your encoder emits 0x3E200000 for 0.15625 and the tool agrees, your sign, exponent and mantissa packing is correct.
Common pitfalls
Reading the stored exponent as the real one. The exponent field is biased — subtract 127 for single or 1023 for double to get the true power of two. A raw exponent of 124 means 2^−3, not 2^124. The tool shows both the raw value and E = exp − bias so you do not have to.
Expecting decimal fractions to be exact. Values like 0.1, 0.2 and 0.3 have no finite binary form, so they are stored rounded. Comparing them with === fails by design. Paste them in and the nonzero repeating mantissa explains why an epsilon comparison is the right fix.
Pasting a bit pattern of the wrong width. A 64-bit hex word will not decode as a single-precision float and vice versa. Match the precision toggle to the number of bits you have — 8 hex digits for single, 16 for double — or the tool rejects the input.
Privacy
Every step runs as plain JavaScript inside your browser tab using ArrayBuffer and DataView. The decimal value you type, the bit patterns you paste and the decoded results never leave the page, and nothing is logged. The one thing to know: the decimal input and the precision are encoded in the page URL so a shared link reopens the same number, which means a link pasted into chat records that value in the recipient server's access log. For anything sensitive, use the copy buttons and paste the text rather than sharing the URL.
FAQ
Tool combos
Folks in your role tend to reach for these alongside this tool.
- Add Line Numbers Number every line of pasted text — set start, step and separator, zero-pad to align, skip blanks, or strip numbers back off — browser-only
- AES Text Encryptor Encrypt & decrypt text with a password — AES-256-GCM + PBKDF2 via WebCrypto — 100% in your browser, nothing uploaded
- Affine Cipher Encoder & Decoder Encrypt and decrypt the ax+b affine cipher with live modular-inverse check, browser-only
- Age Difference Calculator The exact gap between two birthdays — years/months/days, percentage, and the date one person is twice the other's age — browser-only