Bytes to Integer / Float Converter
Interpret 1, 2, 4 or 8 bytes as signed and unsigned integers or as a float32 or float64, in both big-endian and little-endian order.
Paste the bytes you see in a hex dump or a packet capture to find out which number they encode.
More Byte Array Tools
View all 17The same four bytes can mean a large integer or a small decimal - you need to know the type and byte order the data was written with.
What Is the Bytes to Integer / Float Converter?
The same bytes mean different numbers depending on the type and the byte order they were written with. Enter 1, 2, 4 or 8 bytes in hex and this tool shows every standard interpretation at once: signed and unsigned integers from 8 to 64 bits, 32-bit float and 64-bit double, each read big-endian and little-endian.
When to Use It
- Decoding a field in a binary file format, a sensor reading or a Modbus register.
- Checking a value in a hex dump or a Wireshark capture.
- Understanding IEEE 754 floating-point bytes.
How to Use It
- Enter the bytes in hex, in the order they appear in memory or in the file.
- Read the table - pick the row for the type you expect and the column for the byte order.
Example
The four bytes 40 49 0F DB read as a big-endian float32 are 3.1415927410125732 - the nearest float to pi. The same bytes as a big-endian int32 are 1078530011. The eight bytes 40 09 21 FB 54 44 2D 18 as a big-endian double are 3.141592653589793.
Understanding the Output
Only types whose size matches the number of bytes are shown: 4 bytes give int32, uint32 and float32. When one column shows a sensible number and the other a huge or tiny one, the sensible column is almost always the right byte order.
Limitations
Three, five, six or seven bytes do not match a standard type. Fixed-point, BCD and half-precision (16-bit) floats are not decoded. For the reverse direction, use Integer to Bytes; to just swap the order, use the Endianness Converter.
Frequently Asked Questions
Explore More Tools
Keep going with related categories and our most used tools.