fjordtools / Convert / Number Base
Number Base & Byte Size Converter
Convert integers between hex, binary, octal, decimal and base 36 with exact big numbers and two's complement, and convert byte sizes between KB, KiB, MB, MiB and more. Runs in your browser.
About Number Basehow it works and good to know
Exact, at any size
Integers are handled as arbitrary-precision values, so a 64-bit hash or a 200-digit number converts without rounding. Type a prefix (0x, 0b, 0o) or pick the input base. Underscores and commas between digits are ignored.
Two's complement
For every width the value fits in (8, 16, 32 and 64 bits) the table shows the hex form, and how the same bits read as a signed and an unsigned number. That is what you want when a negative number shows up as 0xffffffff in a debugger.
KB or KiB?
KB, MB and GB are powers of 1000, the way disks and networks are sold. KiB, MiB and GiB are powers of 1024, the way memory and most operating systems count. A bare number is bytes. The size table shows both families side by side.
Privacy
The conversion runs in your browser. Nothing is uploaded or stored.
Related tools
- Base64Encode and decode text, with URL-safe and UTF-8 support.
- Hash & HMACMD5, SHA-1, SHA-256, SHA-384, SHA-512 and HMAC for text and files.
- Color ToolsConvert HEX, RGB and HSL, and check WCAG contrast.
- URL EncoderPercent-encode, decode and take apart URLs and query strings.
- Timestamp ConverterUnix time to dates and back, in any time zone.
- YAML JSON TOMLConvert config files between YAML, JSON and TOML.