Data Storage Converter Formula
Understand the math behind the data storage converter. Each variable explained with a worked example.
Formulas Used
Kilobytes
kb = value / 1024Megabytes
mb = value / pow(1024, 2)Gigabytes
gb = value / pow(1024, 3)Terabytes
tb = value / pow(1024, 4)Bits
bits = value * 8Variables
| Variable | Description | Default |
|---|---|---|
value | Data Size(bytes) | 1073741824 |
How It Works
Data Storage Converter
Conversion Factors from Bytes (Binary)
Note: This converter uses binary (base-2) units where 1 KB = 1,024 bytes.
Worked Example
Convert 1,073,741,824 bytes (1 GB) to other units.
value = 1073741824
- 01KB = 1073741824 / 1024 = 1048576 KB
- 02MB = 1073741824 / 1048576 = 1024 MB
- 03GB = 1073741824 / 1073741824 = 1 GB
- 04TB = 1073741824 / 1099511627776 = 0.000976563 TB
Ready to run the numbers?
Open Data Storage Converter