nanogb
Explainer

GB vs GiB: the difference between decimal and binary units

Illustration of a decimal gigabyte block beside a slightly larger binary gibibyte block

The short answer

A gigabyte (GB) is exactly 1,000,000,000 bytes. A gibibyte (GiB) is exactly 1,073,741,824 bytes, which is 2 to the power of 30. The two names sound alike, but a GiB is about 7.4% bigger than a GB. That gap is the reason a new phone, laptop or memory card can seem to hold less than the number printed on the box.

Both units are official. "Giga" is an SI prefix meaning 10 to the power of 9, one billion, as listed by NIST. "Gibi" is a binary prefix that the International Electrotechnical Commission (IEC) approved in December 1998 for data processing and data transmission. NIST is careful to point out that the binary prefixes are not part of the SI itself; they were simply modelled on it.

Decimal prefixes vs binary prefixes

Decimal (SI) prefixes step up by 1,000 each time: kilo, mega, giga, tera. Binary (IEC) prefixes step up by 1,024 each time: kibi, mebi, gibi, tebi. You can recognise binary units by the small "i" in the symbol: KiB, MiB, GiB, TiB.

Why 1,024? Computers work in base 2, and 2 to the power of 10 happens to be 1,024, very close to 1,000. The IEC explains that early engineers began calling 1,024 bytes a "kilobyte" purely for convenience, since the difference was only 2.4%. The habit stuck as sizes grew into megabytes, gigabytes and terabytes, and the error grew with them.

Exact byte counts

Decimal unitBytesBinary unitBytesBinary is bigger by
1 KB (kilobyte)1,0001 KiB (kibibyte)1,0242.4%
1 MB (megabyte)1,000,0001 MiB (mebibyte)1,048,5764.9%
1 GB (gigabyte)1,000,000,0001 GiB (gibibyte)1,073,741,8247.4%
1 TB (terabyte)1,000,000,000,0001 TiB (tebibyte)1,099,511,627,77610.0%

The pattern is worth remembering: the gap grows with every step, from 2.4% at kilo to almost 10% at tera. The IEC notes it gets closer to 20% at the exa scale. That is why nobody noticed the difference on floppy disks, but almost everyone notices it on a terabyte drive.

Why a 1 TB drive shows about 931 GB

Storage makers measure capacity in decimal units. Apple's support page quotes the typical packaging line: "1GB = 1 billion bytes, and 1TB = 1 trillion bytes; actual formatted capacity less." So a 1 TB drive holds about 1,000,000,000,000 bytes.

Some operating systems and apps divide that number by 1,024 instead of 1,000. Microsoft Windows is the best-known example: it reports file and drive sizes using binary multipliers but still writes the label "GB". Here is the arithmetic:

  • 1,000,000,000,000 bytes ÷ 1,073,741,824 bytes per GiB = about 931.3 GiB
  • 1,000,000,000,000 bytes ÷ 1,099,511,627,776 bytes per TiB = about 0.91 TiB

Nothing is missing. The bytes are all there; they are just being counted with a bigger ruler. On top of that, formatting the drive and installing an operating system use some real space, which is the "actual formatted capacity less" part of the fine print.

Worked examples for common sizes

Size on the boxBytesSame amount in GiB
64 GB64,000,000,000about 59.6 GiB
128 GB128,000,000,000about 119.2 GiB
256 GB256,000,000,000about 238.4 GiB
512 GB512,000,000,000about 476.8 GiB
1 TB1,000,000,000,000about 931.3 GiB
2 TB2,000,000,000,000about 1,862.6 GiB (1.82 TiB)

To convert any value yourself, multiply GB by 0.9313 to get GiB, or multiply GiB by 1.0737 to get GB. The data size converter does this for every unit from bytes to TiB, in both directions.

Which devices use which unit?

Apple: decimal on current software

Apple states that some apps and operating systems, "such as iOS 10 and earlier and OS X Leopard and earlier", report storage in binary. Current iPhone, iPad and Mac software counts in decimal, so the capacity you see in Settings lines up with the box, minus the space used by the system. That matters when you compare an iPhone screen with a Windows PC showing the same files: identical data can produce two different numbers.

Windows: binary values with "GB" labels

As noted above, Windows divides by 1,024 but keeps the familiar labels. A 400 GB drive therefore appears as about 372 "GB", which is really 372 GiB. Some Linux desktops, by contrast, display decimal units.

Android phones

Android phones vary by maker and software version. If the total in your storage settings looks about 7% lower than the box figure before any system space is counted, the phone is almost certainly showing binary values. Our guide on how much storage you need on your phone walks through what else uses up the advertised number.

RAM: binary in practice

Memory chips are built in powers of two, so memory sizes are binary even when sold as "GB". A module labelled 8 GB holds 8 GiB, or 8,589,934,592 bytes. In other words, the GB on a RAM spec and the GB on a storage spec are not the same unit.

What about speeds: megabits vs megabytes?

Internet and network speeds normally use decimal prefixes and bits, not bytes. A 100 megabit per second connection moves 100,000,000 bits each second. Divide by 8 to get bytes: 12.5 MB/s. If a download tool then shows progress in MiB/s, the same connection reads about 11.9 MiB/s. The IEC notes that network designers and telecom engineers have historically used "megabit" in both senses too, which is why it helps to check the symbol. The download time calculator handles the bits-to-bytes step for you.

How to tell which unit you are looking at

  1. Look for the "i". GiB, MiB and TiB are always binary. GB, MB and TB should be decimal, but some software uses them for binary values.
  2. Compare with the box. If a 256 GB device reports about 238 as its total, it is counting in GiB.
  3. Check the size of a known file. A file of exactly 1,000,000,000 bytes shows as 1 GB in decimal software and about 0.93 GB in binary software.
  4. Remember the rule of thumb. Roughly 2% gap at KB, 5% at MB, 7% at GB, 10% at TB.

Key takeaways

  • 1 GB = 1,000,000,000 bytes (SI decimal). 1 GiB = 1,073,741,824 bytes (IEC binary).
  • The gap is 7.4% at the giga level and 10% at the tera level, so it matters more as drives get bigger.
  • A 1 TB drive shown as about 931 "GB" is complete; it is being displayed in GiB.
  • Current Apple software shows decimal values; Windows shows binary values with GB labels; RAM is binary.

For more explainers on units, speeds and storage, browse all nanogb guides or the full list of calculators and converters.

Sources

Frequently asked questions

What is the difference between GB and GiB?

A gigabyte (GB) is 1,000,000,000 bytes, using the decimal SI prefix giga. A gibibyte (GiB) is 2^30 = 1,073,741,824 bytes, using the binary IEC prefix gibi, so 1 GiB is about 7.4% larger than 1 GB.

Is 1 GB equal to 1024 MB?

In the official decimal system, 1 GB = 1,000 MB. The 1,024 relationship belongs to the binary units: 1 GiB = 1,024 MiB. Some software still uses GB and MB loosely to mean the binary values.

Why does my 1 TB drive show only 931 GB?

The drive holds about 1,000,000,000,000 bytes. Software that divides by 1,024 three times gets about 931.3, which is really 931 GiB even when it is labelled GB. Formatting and system files take a little more.

Does iPhone use GB or GiB?

Apple says iOS 10 and earlier, and OS X Leopard and earlier, reported capacity in binary units. Current iPhone, iPad and Mac software counts in decimal, matching the box.

Is RAM measured in GB or GiB?

Memory chips come in powers of two, so a module sold as 8 GB actually holds 8 GiB, which is 8,589,934,592 bytes. Storage drives, by contrast, are sold in decimal gigabytes.

More guides

All guides →