Em size is a unit defined by the height of characters. It is used in font sizing in typography, and consequently is used in web development. The origin of the name "em" is from metal type printing, where the "m" character type happened to be a square. While in the past this was a physical property of the "m" type, in modern design contexts it is an arbitrary size representing the "design space" of a digital font. This means the actual height of text in pixels can vary between fonts, despite having the same em size.
This is also the origin of em dashes, where they are one "m" character in width. En dashes are similarly the width of a single "n" character.
More on this can be read here.