Bytes to MB Converter
Convert a raw byte count to megabytes, the way a file size from a log or an API response needs reading.
1 Byte = 0.000001 MB Both units are exactly defined, so this conversion is exact.
| Byte | Megabyte (decimal) |
|---|---|
| 1 B | 0.000001 MB |
| 2 B | 0.000002 MB |
| 5 B | 0.000005 MB |
| 10 B | 0.00001 MB |
| 25 B | 0.000025 MB |
| 50 B | 0.00005 MB |
| 100 B | 0.0001 MB |
| 500 B | 0.0005 MB |
| 1,000 B | 0.001 MB |
Everything you type here is processed on your own device. No input is sent to a server, logged, or stored.
What the Bytes to MB Converter does
This bytes to MB converter will convert a raw byte count to megabytes, the way a file size from a log or an API response needs reading. It covers 5 units and converts in both directions, so you can start from whichever figure you already have. It is most often used for reading a Content-Length header or an API response that reports bytes. You may also want the bytes to GB converter.
How to use it
- Type the byte figure into the first box.
- The megabyte (decimal) value appears immediately in the second box.
- Use the swap button to run the conversion the other way, or change either dropdown for a different unit.
- Press Copy result to put the converted figure on your clipboard.
How it works
Raw byte counts are what programs report internally — Content-Length headers, stat calls, database columns — because a byte is the unit the machine actually works in. This page uses the decimal definition, where each step up is a factor of 1000. That is the SI meaning, the one drive and network manufacturers use, and the one the SI prefixes kilo-, mega- and giga- have everywhere else in science. The binary units — kibibyte, mebibyte, gibibyte, each a factor of 1024 — are listed in the dropdown if you need them.
Exact. A byte count is a whole number, so the only imprecision is whatever decimal places you choose to keep afterwards.
Byte to Megabyte (decimal) reference table
| Byte | Megabyte (decimal) |
|---|---|
| 1 B | 0.000001 MB |
| 2 B | 0.000002 MB |
| 5 B | 0.000005 MB |
| 10 B | 0.00001 MB |
| 25 B | 0.000025 MB |
| 50 B | 0.00005 MB |
| 100 B | 0.0001 MB |
| 250 B | 0.00025 MB |
| 500 B | 0.0005 MB |
| 1,000 B | 0.001 MB |
All supported units and their factors
| Unit | Symbol | Base units per unit | Notes |
|---|---|---|---|
| Byte | B | 1 | exact |
| Megabyte (decimal) | MB | 1000000 | exact |
| Kilobyte (decimal) | kB | 1000 | exact 1000 bytes — the SI meaning used by drive manufacturers. |
| Gigabyte (decimal) | GB | 1000000000 | exact |
| Mebibyte (binary) | MiB | 1048576 | exact |
When to use it
- Reading a Content-Length header or an API response that reports bytes.
- Turning a log file size into something quotable in a report.
- Checking an upload against a limit expressed in megabytes.
Common mistakes to avoid
- Dividing by 1,048,576 when the figure will be compared against a decimal MB limit.
- Confusing a byte count with a bit count — divide bits by eight first.
- Rounding to zero decimal places on small files, which turns every sub-megabyte file into 0 MB.
Frequently asked questions
How many bytes in a megabyte?
1,000,000 decimal, or 1,048,576 for the binary mebibyte.
Which does my programming language use?
Most report raw bytes and leave the formatting to you. Whichever you divide by, label it so the next reader knows.
What about very small files?
Below about 100,000 bytes, kilobytes read better than megabytes. The dropdown switches units without re-entering the number.