Data Size Units and Memory Units Cheat Sheet
- Bit (b): The smallest unit of digital information (0 or 1).
- Nibble: 4 bits.
- Byte (B): Commonly 8 bits.
Unit |
Abbreviation |
Factor |
Exact Bytes |
Kilobyte |
KB |
10³ |
1,000 bytes |
Megabyte |
MB |
10⁶ |
1,000,000 bytes |
Gigabyte |
GB |
10⁹ |
1,000,000,000 bytes |
Terabyte |
TB |
10¹² |
1,000,000,000,000 bytes |
Petabyte |
PB |
10¹⁵ |
1,000,000,000,000,000 bytes |
Exabyte |
EB |
10¹⁸ |
1,000,000,000,000,000,000 bytes |
Unit |
Abbreviation |
Factor |
Exact Bytes |
Kibibyte |
KiB |
2¹⁰ |
1,024 bytes |
Mebibyte |
MiB |
2²⁰ |
1,048,576 bytes |
Gibibyte |
GiB |
2³⁰ |
1,073,741,824 bytes |
Tebibyte |
TiB |
2⁴⁰ |
1,099,511,627,776 bytes |
Pebibyte |
PiB |
2⁵⁰ |
1,125,899,906,842,624 bytes |
Exbibyte |
EiB |
2⁶⁰ |
1,152,921,504,606,846,976 bytes |
Term |
Typical Size |
What Is It? |
Where Is It? |
Who Uses It? |
Why This Size? |
Cache Line |
~64 bytes (on modern CPUs) |
Smallest chunk of data fetched/stored by CPU cache |
CPU caches (L1, L2, L3) |
CPU hardware, cache controller |
Balances transfer overhead vs. spatial locality; 64 bytes is common for modern architectures |
Memory Page |
4 KB (commonly), 2 MB, 1 GB |
Fundamental unit of virtual memory management |
System RAM, managed by the OS |
OS, CPU MMU (Memory Management Unit), TLB |
Standard 4 KB minimizes overhead of page tables; larger pages (2 MB, 1 GB) reduce TLB pressure for big data workloads |
Disk Block |
Typically 512 bytes or 4 KB |
Smallest addressable unit on storage devices (HDD, SSD) |
Physical storage (disk/SSD) |
Disk controllers, file systems |
Historically 512 bytes was standard; many drives now use 4 KB for efficiency and error correction |
File-System Block |
Often 4 KB, can be bigger |
Unit in which file systems allocate and manage disk space |
File system layer on top of disk blocks |
OS file system driver, user-level I/O |
Matches or aligns with disk block size and common page size for simpler I/O and reduced fragmentation |