Of all grammatical errors, misuse of these abbreviations is the one most commonly encountered. Time and again one reads things like: "Any beverage, i.e., tea ..." The writer intends to say, "Any beverage, for example, tea ...", but actually says, "Any beverage, that is, tea ...", which is wrong because although tea is a beverage there are many beverages other than tea.
These abbreviations are Latin in origin. The fact that Latin is no longer studied in American high schools (I admit that it is of little use in the modern world) may help to explain why many American writers misuse these abbreviations (though the cause is nevertheless probably as suggested above).
* "e.g." is short for exempli gratia, and means "for example".
* "i.e." is short for id est, and means "that is".
Use "e.g." when you want to give an example (or several examples) of something just mentioned. Use "i.e." when you wish to explain briefly or to clarify what you just said, or say the same thing in other words.
E.g., "Take any common object at hand, e.g., a pen, and apply your latent psychokinetic powers to it (i.e., try to cause it to move by the power of your will)."
Instead of "e.g." and "i.e." some people write "eg." and "ie.". While not correct this may be regarded as minimally acceptable, since it is still clear what the abbreviations mean, i.e., not the Latin words but the meaning ("for example" and "that is" respectively).
Anyone who uses one of these abbreviations when they mean the other may be considered basically uneducated and a danger to themselves and to society at large.