Bit and byte

Bits and Bytes

A bit (short for binary digit) is the smallest and most fundamental unit of information in computing. A bit can hold exactly one of two values: 0 or 1. Every piece of data a computer stores or processes - numbers, text, images, sound, instructions - is ultimately composed of individual bits. The abbreviation for bit is a lowercase b.

On its own, a single bit can only distinguish between two states (on or off, true or false, yes or no). To represent more complex information, bits are grouped together. The standard grouping is the byte, which consists of exactly 8 bits. The abbreviation for byte is an uppercase B. This distinction matters in practice: a file size of 10 MB (megabytes) is eight times larger in bits than 10 Mb (megabits), so confusing the two cases leads to significant errors when comparing storage capacities or data transfer speeds.

With 8 bits per byte, a single byte can represent 28 = 256 distinct values (0 to 255). This is why a byte is the standard unit for storing one character of text in ASCII, one channel of an RGB colour value, or one sample of audio data. Larger units - kilobyte, megabyte, gigabyte - are all built on top of the byte as the base unit.

 Key Takeaways

  • A bit (b) is the fundamental unit of information: a single binary digit, either 0 or 1.
  • A byte (B) is a group of exactly 8 bits. One byte can represent 256 distinct values.
  • The abbreviations are case-sensitive: lowercase b = bit; uppercase B = byte. Mixing them up leads to errors when comparing file sizes or transfer speeds.
  • All data in a computer - text, images, sound, instructions - is ultimately stored as sequences of bits grouped into bytes.