I.e. is an abbreviation for id est from the Latin meaning “that is, in other words”.

E.g. is an abbreviation for exempli gratia from the Latin meaning “for example”.

The abbreviations are often italicized because they are abbreviations of foreign words. However, they are both common enough that you’ll often see them in non-italicized font. For example, “etc.” is also a Latin abbreviation, but it is incredibly common and therefore never italicized.