before vowels reduced to ep-, before aspirated vowels eph-, word-forming element meaning "on, upon, above," also "in addition to; toward, among," from Greek epi "upon, at, close upon (in space or time), on the occasion of, in addition," also "after," from PIE *epi, *opi "near, at, against" (source also of Sanskrit api "also, besides;" Avestan aipi "also, to, toward;" Armenian ev "also, and;" Latin ob "toward, against, in the way of;" Oscan op, Greek opi- "behind;" Hittite appizzis "younger;" Lithuanian ap- "about, near;" Old Church Slavonic ob "on"). A productive prefix in Greek; also used in modern scientific compounds (such as epicenter).
In Latin assimilated to following -c-, -f-, -g-, -p-, and often -r- and -m-. In Old French the prefix appears in the full Latin form only "in learned adoptions of old Latin compounds" [OED], and in popular use it was represented by sous-, sou-; as in French souvenir from Latin subvenire, souscrire (Old French souzescrire) from subscribere, etc.
The original meaning is now obscured in many words from Latin (suggest, suspect, subject, etc.). The prefix is active in Modern English, sometimes meaning "subordinate" (as in subcontractor); "inferior" (17c., as in subhuman); "smaller" (18c.); "a part or division of" (c. 1800, as in subcontinent).