Convert Hexfloat to Float
Create a floating-point number from a hexfloat number. Runs entirely in your browser, so your data never leaves your device.
Runs on your device, nothing uploaded
0 chars · 0 lines
Output
Create a floating-point number from a hexfloat number.
Type or paste above to see the result here.
What you paste never leaves this tab
Convert Hexfloat to Float is JavaScript that your browser has already downloaded, and it does the whole job on your own machine. On a normal site, whatever you type in is sent to a server that can log it, cache it or keep it. Here it is read and transformed inside this tab and nowhere else.
- No upload
- No length limit
- Works offline once loaded
- Nothing stored or logged
How to use Convert Hexfloat to Float
- 1. Paste the hex float. Enter a literal like 0x1.921fb54442d18p+1. A missing 0x is read with a note (1.8p3 as 0x1.8p3), and f, F and L suffixes, inf and nan are accepted.
- 2. Pick how to show it. Show as Shortest gives the shortest decimal that reads back the same double, such as 12 or 3.141592653589793; Exact decimal writes every digit. A literal with more than 13 hex fraction digits is rounded, with a warning.
- 3. Copy the decimal. Copy the decimal, or the 64-bit IEEE hex bits listed under it, into your notes or test.
When to use Convert Hexfloat to Float
Convert Hexfloat to Float parses C99 hexadecimal floating-point literals, the 0x1.8p3 style notation that expresses a mantissa and a power-of-two exponent exactly, and returns the decimal number it represents. It is aimed at anyone reading numerical code or debug output that uses this format.
- Reading a printf %a format output. A C or C++ program printed a floating-point value using the %a format specifier for exact reproducibility, and you need the ordinary decimal number to sanity check a calculation.
- Debugging a floating-point precision issue. You are comparing bit-exact hexfloat values from a numerical library's test suite and need to see the actual decimal magnitude each literal represents.
- Understanding a compiler's constant folding output. A compiler explorer or disassembly shows a floating-point constant in hexfloat form, and converting it to decimal confirms it matches the source literal you expected.
Examples
One and a half x 8
Input
0x1.8p3
Output
12
Half
Input
0x1p-1
Output
0.5
About the Convert Hexfloat to Float tool
Convert Hexfloat to Float is a free online tool that works entirely inside your web browser. Create a floating-point number from a hexfloat number. Because the processing happens on your own device, nothing you enter is uploaded, logged or stored anywhere.
This page is one of 108 Hex utilities on EditSafely. Each one does a single job well, and all of them follow the same rule: your input stays on your machine.
You can shape the output with the Show as setting, and the result refreshes the moment you change it. 2 worked examples further down the page show exactly what the tool produces for real inputs.
Because nothing leaves your device, the tool is suitable for sensitive content such as internal documents, credentials or customer data. It also responds instantly, since every step is handled on your own machine rather than by a remote API.
Frequently asked questions
Is Convert Hexfloat to Float free to use?
Yes, it is completely free. All 2,943 tools on EditSafely work without an account, a subscription or usage limits.
Is it safe to paste sensitive or confidential data?
Everything happens locally. Your browser downloads the tool's code once, then does all the processing itself; nothing you enter is transmitted, stored or logged. You can even go offline after the page loads and it will still work.
How much text can I process at once?
There is no fixed limit; your device's memory is the ceiling. Up to 10 MB the result updates as you type, after a short pause that grows with the size. Above 10 MB a Run button appears so typing stays smooth, and files open up to 50 MB. A very long result shows its first 2,000 lines on screen, while Copy and Download always include all of it.
Do I need to sign up or install anything?
No. The tool works in any modern browser on desktop, tablet or phone. There is no account to create, no extension to add and no software to install.
How do I use the result?
The output panel has a one-click copy button, and you can keep refining the input while you work; the result updates in place as you type.
Related tools
All Hex Tools →Convert Float to Hexfloat
Create a hexfloat number from a floating-point number.
Convert a Floating Point Number to Hex
Find the hex representation of a floating-point number.
Convert Hex to a Floating Point Number
Find the floating-point number from its hex representation.
Convert Hex to Decimal
Quickly convert hexadecimal numbers to decimal numbers.