interjection expressing various emotions (fear, surprise, pain, invocation, gladness, admiration, etc.), 1530s, from Middle English o, from Old French ô, oh or directly from Latin o, oh; a common Indo-European interjection (compare Greek ō; Old Church Slavonic and Lithuanian o; Irish och, Old Irish a; Sanskrit a). But it is not found in Old English (which had ea and translated Latin oh with la or eala) or the older Germanic languages except those that probably borrowed it from Greek or Latin.
The present tendency is to restrict oh to places where it has a certain independence, & prefer o where it is proclitic or leans forward upon what follows .... [Fowler]
Often extended for emphasis, as in Oh, baby, a stock saying from c. 1918; oh, boy (by 1917); oh, yeah (1924). Reduplicated form oh-oh as an expression of alarm or dismay is attested from 1944 (as uh-oh by 1935). Oh-so "so very" (often sarcastic or ironic) is by 1916. Oh yeah? "really? Is that so?" is attested from 1930.