Quickly convert data storage units between bytes, kilobytes, megabytes, gigabytes, terabytes, and petabytes. Supports both binary (1024-based) and decimal (1000-based) conversions.
Data storage units look simple — kilobyte, megabyte, gigabyte, terabyte — but there's a six-decade-old fight underneath them. Computer scientists defined them in base 2 (1 KB = 1,024 bytes), because that's the natural unit when memory is addressed in powers of 2. Marketing and the metric system defined them in base 10 (1 KB = 1,000 bytes), because that's what "kilo" means in SI. Both standards now coexist, and the resulting confusion is why a "1 TB" external drive shows as ~931 GB in your operating system: the drive maker used decimal, your OS uses binary.
The IEC tried to fix this in 1998 with new names — kibibyte (KiB), mebibyte (MiB), gibibyte (GiB), tebibyte (TiB) — explicitly meaning the binary powers (1024, 1024², 1024³, 1024⁴). The new names never caught on in everyday speech, but they're how the IEC, ISO, IEEE, and Linux distributions write it precisely. This converter handles both standards so you can translate between what a vendor advertises and what your machine actually shows.
Beyond the binary-vs-decimal headache, this calculator is useful any time you need to size storage budgets, estimate file counts at a given resolution, or convert between units that span eight orders of magnitude (bytes to petabytes). Once you internalize the powers of 2 (1024² = 1 MiB, 1024³ = 1 GiB), most conversions become mental arithmetic.
**Scenario:** You buy a 2 TB external SSD. After formatting, Windows shows 1.82 TB free. **Calculation:** 2 TB (decimal) = 2,000,000,000,000 bytes = 1,818.99 GiB ≈ 1.82 TiB. The number of bytes is exactly what was advertised; Windows just uses binary GiB and labels them "GB" (with the leading 1.82 figure). Nothing is missing. **Result:** The drive really is 2 TB by the marketing definition (2 × 10¹²) and 1.82 "GB" by Windows' binary-but-mislabeled definition. Modern Linux and macOS sometimes use the correct "TiB" suffix to disambiguate.
**Scenario:** You shoot RAW on a 24 MP camera. Each RAW file is ~30 MB. You take 200 photos per shoot, 50 shoots per year. How much storage do you need annually? **Calculation:** 30 MB × 200 = 6,000 MB = 6 GB per shoot. 6 GB × 50 = 300 GB/year. Add JPG previews (2 MB each × 10,000 photos = 20 GB). Total: ~320 GB/year. Five years of shoots: 1.6 TB. **Result:** A 2 TB SSD covers about 6 years of shooting. Add a second 2 TB for offsite backup. For a serious photography library, expect storage costs of $100–200/year (including cloud backup) as a hidden line item.
**Scenario:** Your application stores 250 GB of user uploads on AWS S3 Standard at $0.023/GB-month. **Calculation:** 250 GB × $0.023 = $5.75/month = $69/year. With AWS using decimal (1 GB = 10⁹ bytes), you're billed on what you actually store, not the OS-reported figure. **Result:** S3 Standard at $0.023/GB-month makes 250 GB cost about $5.75/month. Tiered to Standard-IA ($0.0125) or Glacier Deep Archive ($0.00099), the same data costs $3.13 or $0.25/month respectively. Egress fees, request fees, and lifecycle transitions are additional and often bigger than storage itself.
**Use storage conversion when you need to:**
- **Buy storage**: figure out what an advertised "8 TB NAS" really delivers in your OS (about 7.28 TiB). - **Size cloud storage budgets**: AWS, GCP, Azure all use decimal GB for pricing. The S3 "$0.023/GB-month" is decimal GB. - **Plan backup retention**: incremental backups need careful sizing — daily 50 GB diff × 30 days = 1.5 TB per month per system. - **Estimate database growth**: rows × average row size × growth rate. A million-row table with 1 KB rows is 1 GB; at 10x growth it's 10 GB. - **Convert from bandwidth to storage**: a 100 Mbps stream for one hour is 100 × 3600 / 8 = 45,000 MB ≈ 45 GB of recorded video. - **Translate between RAM and disk**: RAM is always sold in binary GiB labeled "GB" (8 "GB" RAM = 8,589,934,592 bytes). Disk advertised in decimal.
**Real-world units you'll see in 2026:**
- **Phones**: 128 GB, 256 GB, 512 GB, 1 TB (decimal) - **SSDs**: 500 GB, 1 TB, 2 TB, 4 TB (decimal) - **HDDs**: 4 TB, 8 TB, 16 TB, 22 TB (decimal) - **RAM**: 8 GB, 16 GB, 32 GB, 64 GB (binary, despite the "GB" label) - **Cloud blob**: priced per GB-month (decimal); a 1 TB monthly bill = 1,000 GB - **Enterprise NAS**: PB-scale starts to matter; 1 PB ≈ 1024 TB binary or 1000 TB decimal
Calculate download time from file size and internet speed.
Calculate aspect ratio from width and height, or find missing dimensions.
Calculate pixels per inch from screen resolution and display size.
Encode or decode text for safe use in URLs.
Estimate the cost of running AI models like GPT-4o, Claude, and Gemini via their APIs.
Generate secure random passwords with customizable length and character types.
MB
1,024
GB
1
TB
0.000977
Bytes
1,073,741,824
| Unit | Value |
|---|---|
| Bytes | 1,073,741,824 |
| Kilobytes (KB) | 1,048,576 |
| Megabytes (MB) | 1,024 |
| Gigabytes (GB) | 1 |
| Terabytes (TB) | 9.7656e-4 |
| Petabytes (PB) | 9.5367e-7 |
| Standard | Binary (base 1024) |