"native or permanent resident of London," specifically the City of London, more precisely one born or living "within the sound of Bow-Bell" (see Bow bells); c. 1600, usually said to be from Middle English cokenei, cokeney "spoiled child, milksop" (late 14c.), originally cokene-ey "cock's egg" (mid-14c.). The most likely disentangling of the etymology is to start from Old English cocena "cock's egg" -- genitive plural of coc "cock" + æg "egg" -- medieval term for "runt of a clutch" (as though "egg laid by a cock"), extended derisively c. 1520s to "town dweller," gradually narrowing thereafter to residents of a particular neighborhood in the East End of London. Liberman, however, disagrees:
Cockney, 'cock's egg,' a rare and seemingly obsolete word in Middle English, was, in all likelihood, not the etymon of ME cokeney 'milksop, simpleton; effeminate man; Londoner,' which is rather a reshaping of [Old French] acoquiné 'spoiled' (participle). However, this derivation poses some phonetic problems that have not been resolved.
The characteristic accent so called from 1890, but the speech peculiarities were noted from 17c. As an adjective in this sense, from 1630s. Related: Cockneydom; Cockneyish.
proprietary name of a drink mix, 1906, probably based on Latin ovum "egg" (see ovary), because eggs are one of the ingredients.
also egg-head, 1907, "bald person," from egg (n.) + head (n.). Sense of "intellectual" is attested from 1918, among Chicago newspapermen; popularized by U.S. syndicated columnist Stewart Alsop in 1952 in reference to Adlai Stevenson's presidential campaign.
Adlai Stevenson once told what it was like to be the rare intellectual in politics. "Via ovicapitum dura est," he said, the way of the egghead is hard. [New York Times, Oct. 28, 1982]