Skip to main content
CalculatorAnything
Popular
Mortgage CalculatorPercentage CalculatorAge CalculatorBMI CalculatorGPA CalculatorWork Hours Calculator
Categories
Finance Business Percentage Date & Time Health Math Everyday Construction
All Calculators About

File Size Converter

Convert file sizes between bytes, kilobytes, megabytes, gigabytes, and terabytes.

Unit convention: KB, MB, GB and TB selections use binary multiples (1,024 bytes per KB; GB means 1,024³ bytes here, equivalent to GiB). This differs from decimal GB used by some providers.

About the File Size Calculator

File sizes scale from bytes up to terabytes, and converting between them is a frequent need when checking storage space, upload limits, or download sizes. This calculator converts any file size between bytes, kilobytes, megabytes, gigabytes, and terabytes instantly.

How It Works

The calculator converts your input value to bytes using the binary (1024-based) scale that operating systems typically use for file sizes, then converts that byte value into your target unit.

Value (bytes) = Input × 1024^(unit power); Result = Value (bytes) / 1024^(target unit power). 1 KB = 1024 B, 1 MB = 1024 KB, 1 GB = 1024 MB, 1 TB = 1024 GB.

Worked example

Scenario: Converting 2.5 GB to megabytes.

  1. Binary units: 1 GB = 1,024 MB.
  2. 2.5 × 1,024 = 2,560 MB.
  3. In bytes: 2.5 × 1,024³ = 2,684,354,560 bytes.

Result: 2.5 GB = 2,560 MB.

Tips and common mistakes

  • This calculator uses binary units (sometimes written GiB, MiB), as Windows and most file managers do.
  • Drive makers advertise in decimal units, which is why a '1 TB' drive shows about 931 GB.
  • Small results are shown to full precision rather than rounded to zero — 500 KB is 0.000477 GB.

Assumptions & Limitations

  • Uses the binary (1024-based) definition of kilobyte, megabyte, etc., which matches how Windows, macOS, and most operating systems report file and storage sizes.
  • Some contexts (like hard drive marketing) use a decimal 1000-based definition instead, which would produce slightly different numbers.
  • Storage device manufacturers often advertise capacity using the decimal (1000-based) standard, which is why a '1TB' drive shows less than 1024 GB of usable space when viewed in most operating systems.

Bits, bytes and binary units

Eight bits make one byte. Decimal storage units commonly use powers of 1,000 (KB, MB, GB), while binary units use powers of 1,024 and are more precisely named KiB, MiB and GiB. Software and device manufacturers may display these conventions differently.

This distinction explains why the capacity shown by an operating system can appear smaller than the number printed on a storage device.

Frequently Asked Questions

Why does my hard drive show less space than advertised?

Storage manufacturers typically use the decimal definition (1 TB = 1,000,000,000,000 bytes) for marketing, while operating systems display capacity using the binary definition (1 TB = 1024 GB in binary terms), so a drive shows a smaller number than the label suggests.

What is the difference between KB and kb?

A capital B (KB, MB, GB) refers to bytes, while a lowercase b (Kb, Mb, Gb) refers to bits — since one byte equals 8 bits, mixing these up can cause an 8x error, which matters especially when comparing file sizes to internet speeds.

How many photos fit in a gigabyte?

It depends heavily on photo resolution and format, but a typical modern smartphone photo (3-5 MB) means roughly 200-300 photos could fit in a single gigabyte.

What's the difference between GB and GiB?

A GiB is 1,024³ bytes (binary); a decimal GB is 1,000³ bytes. This calculator treats GB as 1,024³ bytes.

Related Calculators

Data Transfer Time CalculatorScientific Notation Calculator