A megabyte is officially 1 000 000 bytes, because mega means 1 000 000.

To resolve the confusion with 1 048 576 in data processing, in December 1998 the International Electrotechnical Commission created new prefixes for binary multiples (q.v. for fuller explanation).

In brief: kibi is 1024 (= 210), mebi is 1 048 576 (= 10242 = 220), then gibi, tebi, pebi, ebi. Their symbols have a capital letter then i: thus KiB = kibibyte, MiB, GiB etc.

The megabyte usually used to mean mebibyte in computing, but the new more accurate binary prefixes should now be used.