gizmobench

Bytes to MB Converter

Bytes to MB is a division, and the divisor is either 1,000,000 or 1,048,576 depending on which megabyte is meant. This page opens on the decimal one: Byte in the From box and Megabyte (MB) in the To box, 1,000,000 bytes to the MB, which is the megabyte of file sizes quoted in listings, data plans and transfer rates. So 1,500,000 bytes is 1.5 MB, 5,000,000 bytes is exactly 5 MB and 123,456,789 bytes is 123.456789 MB, each of them just the byte count with the decimal point moved six places. The binary megabyte, properly the mebibyte (MiB), is 1,048,576 bytes and it is never more than a glance away: it sits in the list under the headline, so 5,242,880 bytes reads 5.24288 MB and exactly 5 MiB on the same screen. That is the gap the two definitions make at this size, 4.86 percent, small enough to ignore in conversation and large enough to matter against a hard limit. The swap button between the boxes reverses the pair into megabytes to bytes, and the input takes a pasted 5,242,880 or a typed 5e6 equally.

To0.000001
Category
Digital storage
Base unit
byte

1 B in every digital storage unit

  • Bitbit
    8
  • KilobytekB
    0.001
  • MegabyteMB
    0.000001
  • GigabyteGB
    1e-9
  • TerabyteTB
    1e-12
  • KibibyteKiB
    0.0009765625
  • MebibyteMiB
    9.536743e-7
  • GibibyteGiB
    9.313226e-10
  • TebibyteTiB
    9.094947e-13

Common questions

How many bytes are in a megabyte?
1,000,000 in the decimal megabyte (MB) this page starts on, and 1,048,576 in the binary one, the mebibyte (MiB). Both units are in the To menu, spelled apart, and both appear in the list under any answer, so you are never choosing blind. A file manager that writes MB usually means the second: Windows Explorer and the -h output of Linux tools count in 1,024s, while a data plan or a download size is normally the first.
Worked example: how many MB is 5,242,880 bytes?
5.24288 MB, and exactly 5 MiB. The rest of the list for that size fills in the picture: 41,943,040 bits, 5,242.88 kB, 5,120 KiB, 0.00524288 GB and 0.0048828125 GiB. Each row carries its own Copy button, and Copy result above the list copies the headline figure without the thousands separators it is displayed with.
What is the formula for bytes to MB?
MB = bytes / 1,000,000 for the decimal reading and MiB = bytes / 1,048,576 for the binary one. Reversed they are bytes = MB x 1,000,000 and bytes = MiB x 1,048,576, which is what the swap button sets up: 1 MB gives 1,000,000 bytes and 1 MiB gives 1,048,576. Choosing a different unit in either menu changes the divisor, never the byte count you typed.
Is a 10 MB upload limit 10,000,000 bytes or 10,485,760?
Both numbers get called 10 MB and the page cannot know which one a given service means, so the safe move is to convert both and respect the smaller. 10,000,000 bytes is 10 MB decimal and 9.53674316406 MiB, while 10,485,760 bytes is 10 MiB and 10.48576 MB. The difference is 485,760 bytes, which is 0.48576 MB, enough to fail a file sized right up against the line.
Why does a 1,000,000 byte file show up as 0.95 MB?
Because whatever showed it was dividing by 1,048,576. This page gives that reading as 0.953674316406 MiB, which a file manager writing MB would round to 0.95. Nothing has gone missing: it is one byte count under two definitions of the same word. The same effect scales up, so 10,000,000 bytes is 9.53674316406 MiB and 25,000,000 bytes is 25 MB decimal.
What is 1 byte in MB?
0.000001 MB, which is the smallest figure the page still writes out in full. Below a millionth it switches to exponential notation, so the same byte in GB reads 1e-9 and in GiB 9.313226e-10, while the kilobyte row stays as 0.001. Results are shown to twelve significant digits throughout, which is why a long tail such as 0.953674316406 stops where it does.
How do I convert MB back to bytes?
Press the swap button and the page becomes megabytes to bytes: 1 MB is 1,000,000, 25 MB is 25,000,000 and 1.5 MB is 1,500,000. To work in the binary unit instead, pick Mebibyte (MiB) in the From menu after swapping, where 1 MiB is 1,048,576 bytes and 10 MiB is 10,485,760. Both menus remain available, so the same figure also goes to kB, GB or bits.
Can I paste a byte count with commas, or type 5e6?
Yes to both. Commas are stripped before the number is read, so a 5,242,880 copied out of a file listing works as typed, and scientific notation is parsed, so 5e6 and 5000000 both give 5 MB. If what you enter is not a number, a message under the boxes says so and names what the field takes: digits, one decimal point, and an optional minus sign.
Why does the page open on bytes and megabytes when I last converted something else?
Because a page named for a pair should arrive on that pair. Bytes and the decimal megabyte are set here on load, ahead of the pair the converter remembered, and the main unit converter keeps its own memory: go back to it and nothing has changed. The number you last typed does travel with you, since it is usually the size you are still working on.
Does anything I type leave the browser?
No. The unit table is a constant in the page, the division happens in your browser as you type, and no file, no byte count and no account is sent anywhere. Once loaded, the page keeps converting with the network off.

Conversion factors are the exact legal definitions where one exists. An inch is exactly 2.54 cm and a pound exactly 0.45359237 kg, so those conversions are exact rather than approximate. Temperature uses offsets rather than factors, and that is shown in the working.