Is anything I type sent to a server?
No. Every conversion runs in your browser.
Convert between hex, decimal, binary and octal with two's complement and byte order, inspect IEEE 754 floats bit by bit, and convert byte lists between C, Python and C# syntax.
Loading Number Base Converter…
Loading Number Base Converter…
Firmware work is full of the same few conversions: a register value in hex from a datasheet, the same value as a signed 16-bit integer from a sensor, a float received as four bytes over UART, a byte array that has to move from a Python test script into C. Each one is simple, and each has a trap — a sign bit misread, bytes in the wrong order, a float that is not the number you think it is. This converter keeps all the representations of a value in sync. Type in any base and the others update; choose a width and signedness and it shows the two's complement interpretation, the bytes in big- and little-endian order, the byte-swapped value, and a grid of bits you can click to toggle. The float view decodes IEEE 754 single and double precision into sign, exponent and mantissa, shows the exact decimal value that is stored, and explains subnormals, infinities and NaN payloads. The bytes view converts text to bytes in UTF-8, ASCII or Latin-1 and translates byte lists between the syntaxes of C, Python, C# and Base64.
Input is parsed into a BigInt, so any size works. Prefixes (0x, 0b, 0o) and separators (_, spaces, apostrophes) are accepted, and an invalid digit is named. For a fixed width, values are range-checked and the bit pattern is computed modulo 2^width, so negative numbers show their two's complement form.
Decimal input is rounded to the nearest float32 or float64 with a DataView, exactly as hardware does (round to nearest, ties to even). The stored value is then expanded to an exact decimal — every binary fraction has a finite decimal expansion — which shows immediately whether your literal was representable.
Multi-byte values are shown in big-endian (network order, most significant byte first) and little-endian (what ARM, ESP32, AVR and x86 store in memory). The byte-swapped value is what you get when data is read with the wrong endianness.
Text is encoded with TextEncoder for UTF-8, or byte-by-byte for ASCII and Latin-1 with a clear error for characters those encodings can't represent. Byte lists are decoded back to text with a strict UTF-8 decoder that flags invalid sequences.
Short answers for the things developers usually ask before trusting a tool.
No. Every conversion runs in your browser.
Pick a width (8, 16, 32 or 64 bits) and turn on "signed". The same bit pattern is then shown as both its signed and unsigned value: 0xFFFF at 16 bits is 65535 unsigned and -1 signed. Typing -1 in decimal shows its 16-bit pattern, 0xFFFF.
The converter tells you it overflowed, shows the valid range, and shows the truncated low bits — it never wraps silently. Choose "Any size" for arbitrary-precision integers.
Because 0.1 has no exact binary representation. The float view shows the exact value that is actually stored — for float32, 0.100000001490116119384765625 — which is the root of most floating-point surprises in firmware and finance code.
Both have an all-ones exponent and a non-zero mantissa. The top mantissa bit distinguishes them: 1 is a quiet NaN, which propagates through arithmetic, and 0 is a signaling NaN, which can raise an exception. The remaining bits are the payload, which the float view also shows.
Space-separated hex, plain hex, 0x12, 0x34, C initialisers {0x12, 0x34}, escaped strings \x12\x34, Python b'…' literals, C# new byte[] { … } and Base64. The input format is detected automatically.
Useful follow-ups when one conversion usually turns into three more.
Calculate CRC-8, CRC-16 (Modbus, CCITT, XMODEM), CRC-32 and custom CRCs over text, hex bytes or files, with wire byte order and generated C code.
Convert text to Base64 and back with Unicode-safe browser-side processing.
Convert PNG, JPG, BMP or GIF images into C byte arrays for SSD1306/SH1106 OLEDs and TFT displays — 1-bit, RGB565 and grayscale — with a preview rendered from the bytes.
Want the background and worked examples? There's a longer write-up.
Read the Number Base Converter guide