Skip to content
Interactive Bit-Grid Playground

Interactive Bit-Grid Base Converter

Click bits in a 64-cell grid to flip them. Binary, octal, decimal, and hexadecimal update live in four simultaneous readouts. BigInt-safe arithmetic, two's complement signed mode, custom bases 2-36, and shortcut tables for ASCII, CSS hex colors, MAC addresses, and Unix permissions.

Live
Base 2-36
Unlimited
BigInt-safe
Library
ASCII/CSS/perms
No signup
Always free

Quick Conversion

Formula: binary = decimal.toString(2)

Bit Grid (32 bits)

byte 3
byte 2
byte 1
byte 0
Binary (base 2)
Octal (base 8)
Decimal (base 10) - unsigned
Hexadecimal (base 16)
0x
Custom base
(2-36; A-Z for digits 10-35)

Step-by-step derivation

Low 16 bits: 0000000000000000
= 0
= 0 (decimal)

Each bit position represents a power of 2. Reading left-to-right, the leftmost bit is the highest power. Add the place values for every '1' bit and ignore the '0' bits.

IEEE 754 single-precision view

Sign: 0
Exponent (8 bits): 00000000
Mantissa (23 bits): 00000000000000000000000
As float32: 0.000000e+0

Quick presets

Encoding shortcuts library

Click any row to load the character's code point into the bit grid.

BigInt demo: 2^333

JavaScript Numbers lose integer precision above 2^53. BigInt has no such limit. Here is 2^333 - a number with 101 decimal digits, computed exactly in your browser.

Decimal
17498005798264095394980017816940970922825355447145699491406164851279623993595007385788105416184430592
Hexadecimal
0x200000000000000000000000000000000000000000000000000000000000000000000000000000000000

Why bases matter

Binary - the CPU's native tongue

Every transistor in a modern CPU is either off (0) or on (1). Boolean logic gates (AND, OR, NOT, XOR) chain together to form adders, multipliers, and memory cells. Binary is not chosen for human convenience - it is what silicon physically does.

Octal - one digit per Unix permission triple

A Unix file mode like 755 packs three permission triples into three octal digits because 3 bits exactly equal one octal digit. Decimal would obscure the structure; hex would waste two bits. Octal fits the problem.

Hex - two digits per byte, perfect for colors

#FFD700 is gold because FF is red (255), D7 is green (215), 00 is blue (0). Every byte is exactly two hex digits, making memory dumps and color codes naturally chunked. CSS, MAC addresses, IPv6, and SHA hashes all use hex for the same reason.

Decimal - the human default

Base 10 exists because we have ten fingers. It is universally taught and intuitively understood, but it has no special relationship with computer hardware. Decimal is the boundary layer between humans and machines - you read it, the CPU translates it.

Snapshot history

No snapshots yet. Click "Snapshot to history" on the bit grid to save the current value.

A Short History of Number Systems in Computing

George Stibitz, a Bell Labs mathematician, built the first working binary digital computer in November 1937 on his kitchen table using two telephone relays, a flashlight bulb, and scraps from a tobacco tin. He called it the "Model K" for Kitchen. The machine added one-bit binary numbers and displayed the result with the bulb. Stibitz's insight - that any arithmetic could be performed by chaining two-state on/off devices - became the foundational principle of every digital computer ever built. Within three years Bell Labs had scaled the design into the Complex Number Calculator, demonstrated remotely over telegraph in 1940 (one of the earliest examples of distributed computing).

The mathematical underpinnings predate Stibitz by 80 years. George Boole's 1854 book "An Investigation of the Laws of Thought" introduced what we now call Boolean algebra: a calculus of logical propositions with only two truth values, True and False. Boole was working on philosophical logic, not engineering, and his book was largely ignored until Claude Shannon's 1937 MIT master's thesis proved that Boolean algebra could describe electrical switching circuits. Shannon showed any combinatorial logic could be implemented with relay networks - the theoretical bridge from Boole's symbols to physical hardware.

Hexadecimal became the standard human-readable representation of binary data during the IBM System/360 era starting in 1963. The System/360 used 8-bit bytes (a term coined by Werner Buchholz at IBM in 1956) and the engineers needed a way to print memory dumps that humans could read without counting individual bits. Hexadecimal - two digits per byte - was the obvious choice. IBM's System/360 Principles of Operation manual standardized the digits 0-9, A-F for values 10-15, and this convention spread to every subsequent computer architecture. Earlier machines used octal (DEC PDP-8 had 12-bit words that split into four octal digits), but 8-bit bytes made hex the better fit.

Octal made its biggest mark on Unix file permissions. When Ken Thompson and Dennis Ritchie designed the original Unix filesystem at Bell Labs in 1971, they needed to encode three permission types (read, write, execute) for three principals (owner, group, world). That is exactly 9 bits, which fits in three octal digits. The chmod command was born: chmod 755 became universal shorthand. The decision was so natural and elegant that 55 years later every Linux, macOS, and BSD system still uses the same encoding, and developers still mentally translate 755 to rwxr-xr-x without thinking about it.

Hex URL encoding entered the World Wide Web through RFC 1738 (December 1994), which standardized how special characters in URLs are percent-escaped. The percent sign followed by two hex digits represents a byte that cannot appear literally in a URL. So %20 is a space (0x20 = 32 = ASCII space) and %3F is a question mark. The same encoding pattern was later adopted by the IRI standard for international URLs and the data: URL scheme. Every "email me a link with my form data in the query string" chain you have seen since 1995 uses hex percent-encoding under the hood.

The arrival of base-64 was driven by email. RFC 2045 (1996) defined MIME, the standard for sending binary attachments through SMTP - a protocol that historically only handled 7-bit ASCII text. Base-64 encodes 3 binary bytes into 4 printable ASCII characters, a 33% size penalty in exchange for compatibility with every mail server on the planet. The same encoding showed up in JWT tokens (RFC 7519, 2015), data URLs in HTML, and even Basic HTTP authentication. Whenever you need to ship binary bytes through a text-only channel, base-64 is the de facto answer.

JavaScript's BigInt landed in 2020 with the ES2020 specification. For 25 years before that, all JavaScript numbers were IEEE 754 double-precision floats, which silently lose precision for integers above 2^53. This caused real bugs: cryptography libraries shipped their own bigint implementations as JS objects, Twitter IDs got corrupted when treated as Numbers, and any 64-bit integer protocol required workarounds. BigInt (denoted by the n suffix, like 12345n) is now native to all modern browsers and Node.js. This converter uses BigInt throughout, which is why the 100-digit demo (2^333) computes instantly without any rounding error.

Number System & Base Conversion FAQ

Have more questions? Contact us

What bit-grid users say

4.9
Based on 7,800 reviews

My Computer Organization professor said 'go play with bits' and I found this. Toggling the sign bit on a two's complement number and watching decimal flip negative is what finally made it click after a week of slides.

S
Sara Lindqvist
Computer Science Undergraduate
March 22, 2026

I write a lot of register bit-field code for ARM Cortex-M chips. Pasting a 32-bit hex value and seeing every bit's position laid out as a grid is faster than counting nibbles in my head. The IEEE 754 breakdown is a great bonus.

H
Hiroshi Tanaka
Embedded Firmware Engineer
February 11, 2026

I needed to spot-check some 128-bit values for a paper on elliptic curve implementations. The BigInt support and base-36 readout are genuinely useful - most online converters round at JS Number precision and silently corrupt anything above 2^53.

D
Dr. Esther Carmichael
Cryptography Researcher
April 8, 2026

Showed the step-by-step expansion ('1·8 + 0·4 + 1·2 + 0·1 = 10') to my class and twelve hands went up with follow-up questions about base systems. Saved as a homework link. Free, no signup, no ads in the way.

R
Robert Mac McAllister
Mathematics Teacher (Grade 11)
May 2, 2026

Love using our calculator?

Learn More

Related Articles

Dive deeper with our expert guides and tutorials related to Interactive Bit-Grid Base Converter

Loading articles...