Every time you send a message, save a photo, or stream a song, your device is quietly translating that information into a language made of just two symbols: 0 and 1. This system, called binary, is the foundation on which all digital technology rests. It seems almost too simple to handle the complexity of modern computing, yet these two digits are enough to represent numbers, text, images, audio, and video. Understanding how binary works is the first real step toward understanding how the digital information that surrounds us is actually stored and processed.
Table of Contents
Understanding binary coding
Binary is a base-2 number system, meaning it uses only two digits to represent any value. This stands in contrast to the decimal system we use every day, which is base-10 and uses ten digits, from 0 to 9. According to Built In, binary is the basis for binary code, which uses combinations of 0 and 1 to represent letters, numbers, and other information in a way computers can understand. Each single binary digit is called a bit, short for “binary digit.”
The reason computers rely on binary instead of decimal comes down to physics. A computer’s circuits are built from millions of tiny switches called transistors, and a switch has only two stable states: on or off. As CS Unplugged explains, a bit is usually stored in a memory cell that can be set to a high voltage level representing 1 or a low voltage level representing 0. On a hard disk these two states are represented through magnetism, and on optical media through reflection. Because two states are so easy and reliable to detect electronically, binary became the natural choice for digital machines.
This idea of using two symbols to represent anything is a powerful form of abstraction. The hardware does not need to understand what a letter or a colour is. It only needs to manage patterns of high and low signals. Everything else, from the photo on your phone to the text in this article, is built up from these simple on-off patterns. That single insight, that two states can encode all information, is what makes the entire digital world possible.
How binary numbers work
Binary numbers work on the same principle as decimal numbers, even though they look unfamiliar at first. Both are positional number systems, which means the value of a digit depends on its position within the number. In decimal, the places represent powers of 10: ones, tens, hundreds, and so on. In binary, the places represent powers of 2 instead.
Place value in binary
In a binary number, the rightmost bit has a place value of 2โฐ, which is 1. Moving left, the next bit is worth 2ยน, which is 2, then 2ยฒ, which is 4, then 2ยณ, which is 8, and so on. As TechTarget notes, the decimal value of each bit depends on its position, with the rightmost bit representing 2โฐ and each position to the left doubling in value. Every time you add a bit to the left, you double the range of numbers you can represent.
To convert a binary number to decimal, you multiply each bit by its place value and add the results. Take the binary number 1101. Reading from the left, this is (1 ร 8) + (1 ร 4) + (0 ร 2) + (1 ร 1), which equals 8 + 4 + 0 + 1, giving the decimal value 13. This straightforward method works for binary numbers of any length, and it shows that binary is not mysterious at all, just a different way of grouping quantities.
Bits, bytes, and storage
A single bit is rarely useful on its own. Computers group bits together, and the most important grouping is the byte, which is eight bits. An eight-bit byte has 256 different combinations, allowing it to represent values from 0 to 255. This is why the Computer Science Field Guide points out that eight bits are enough to store something like a person’s age or the day of the month.
For larger values, computers simply use more bytes. Two bytes, or 16 bits, can store numbers from 0 to 65,535, while four bytes can store values into the billions. Every additional bit doubles the available range. This is also why file sizes are measured in bytes, with a kilobyte being roughly a thousand bytes, a megabyte a million, and a gigabyte a billion. When you see a photo described as five megabytes, you are reading a count of how many bytes of binary data it contains.
Standard binary codes
Knowing how to represent numbers in binary solves only half the problem. Computers also need to store letters, punctuation, and symbols. They do this by agreeing on standard codes that assign a specific binary pattern to each character. Without such agreed standards, one machine would have no way of knowing what another machine’s binary patterns were supposed to mean.
ASCII: the early standard for text
The most influential early standard is ASCII, which stands for the American Standard Code for Information Interchange. As GeeksforGeeks describes, ASCII acts as a bridge between human-readable characters and machine-readable numbers by assigning each character a unique numeric value. The original ASCII standard used seven bits per character, which gave it 128 possible codes, numbered 0 to 127.
These 128 codes cover the uppercase letters A to Z, the lowercase letters a to z, the digits 0 to 9, common punctuation marks, and a set of non-printing control characters used for tasks like line breaks and tabs. For example, the capital letter A is assigned the value 65, which in binary is 01000001, while the lowercase a is 97, or 01100001. A neat detail is that switching a letter from uppercase to lowercase simply involves adding 32 to its code. Today, ASCII codes are usually stored in a full eight-bit byte, with the extra leading bit set to 0 to stay compatible with modern systems.
Unicode: a code for every language
ASCII worked well for English, but 128 characters could never hope to represent the scripts of the world, including Devanagari, Bengali, Tamil, and the many other writing systems used across the country. To solve this, Unicode was created. Unicode greatly expands the available space, using encoding schemes that can represent over a million distinct characters. Importantly, the first 128 Unicode characters are identical to the original ASCII codes, so older text remains fully compatible. This is what allows a single web page or document to mix English, Hindi, emoji, and mathematical symbols without any conflict.
Binary coded decimal for precise numbers
Another useful coding scheme is Binary Coded Decimal, or BCD. Instead of converting an entire number into pure binary, BCD encodes each decimal digit separately using four bits. The standard BCD scheme uses an 8-4-2-1 weighting, where the four bits carry place values of 8, 4, 2, and 1. For instance, the decimal number 57 is stored as two groups, 0101 for the 5 and 0111 for the 7, giving 0101 0111.
The advantage of BCD is that it keeps a clear and direct relationship between the stored data and the decimal number a human would read. As Electronics Tutorials explains, this makes BCD ideal for devices such as seven-segment displays in calculators, digital clocks, and electronic meters. It is also valued in financial systems, where exact decimal representation avoids the tiny rounding errors that pure binary can introduce. The trade-off is that BCD uses more storage space than pure binary, since the bit patterns from 1010 to 1111 are simply left unused.
Why these fundamentals matter
Binary coding ties together everything a computer does. Numbers are handled through positional place values, text is handled through agreed standards like ASCII and Unicode, and specialised needs are met by codes like BCD. Each of these is just a different convention for arranging the same two symbols, 0 and 1. Once you grasp that all digital information is built from patterns of bits, the workings of storage, processing, and communication stop feeling like magic and start making sense. In an age where almost every form of information has gone digital, this understanding is genuinely foundational knowledge for anyone studying how information moves through society.
What do you think? If a single byte can only hold 256 different values, how do you think computers manage to store something as rich and detailed as a full-colour photograph or a song? And why might a system designer deliberately choose the less efficient BCD code over pure binary for a particular device?
References
- https://builtin.com/software-engineering-perspectives/binary
- https://www.csunplugged.org/en/topics/binary-numbers/whats-it-all-about/
- https://www.techtarget.com/whatis/definition/binary
- https://www.csfieldguide.org.nz/en/chapters/data-representation/numbers/
- https://www.geeksforgeeks.org/dsa/ascii-table/
- https://en.wikipedia.org/wiki/Binary-coded_decimal
- https://www.electronics-tutorials.ws/binary/binary-coded-decimal.html

Leave a Reply