snaptools
Data Size Converter

Bytes (B)
Kilobytes (KB)
Megabytes (MB)
Gigabytes (GB)
Terabytes (TB)
Petabytes (PB)
Enter a value to see it in every unit
// about this tool

Data Size Converter Online

Updated 2026-07-09

Convert data sizes between bytes, KB, MB, GB, TB, and PB online for free. Enter a value, pick its unit, and SnapTools shows it in every other unit at once — with a toggle for binary (1024) or decimal (1000) counting. Everything runs in your browser, so nothing is uploaded.

The 1024-vs-1000 mismatch trips everyone up: your OS reports a file in binary units while a vendor quotes decimal ones. This converter shows both, side by side, so you always know exactly how big something is — no mental math required.

// how to use

  1. 1 Type a value and pick its unit (B, KB, MB, GB, TB, or PB).
  2. 2 Choose binary (1024) or decimal (1000) units.
  3. 3 Read the value in every other unit and copy the one you need.

// examples

1 MB in bytes (binary)
Input
1 MB
Output
1,048,576 bytes
1 MB in bytes (decimal)
Input
1 MB (base 1000)
Output
1,000,000 bytes

// common uses

Converting file and upload sizes between units Reconciling OS sizes (1024) with vendor specs (1000) Estimating storage and bandwidth needs Reading byte counts from logs and APIs

// faq

Binary units use 1024 (1 KB = 1024 bytes), which is how operating systems and memory usually count. Decimal units use 1000 (1 KB = 1000 bytes), which is how storage manufacturers and networks often report sizes.
Use binary (1024) for RAM, file sizes shown by an OS, and most developer contexts. Use decimal (1000) when matching disk or bandwidth figures from a vendor's spec sheet.
Whole numbers are shown exactly, and fractional values are shown to six significant decimals (trailing zeros trimmed), which is plenty for everyday conversions.
That's the human-readable best-fit size — the largest unit where the value is at least 1 — so you can see the size at a glance.
No — the conversion runs in your browser, so nothing leaves your machine.

Use this via API

Get a free API key →
curl -X POST https://snaptools.dev/api/v1/tools/data-size-converter \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"value":"1 MB"}'
Esc
↑↓ navigate open Esc close