‘The apple of my eye’ is very old and first appears in Old English in a work attributed to King Aelfred (the Great) of Wessex, AD 885, titled Gregory’s Pastoral Care.
Originally it means the central aperture of the eye. Figuratively it is something, or more usually someone, cherished above.
This term,which rests on the ancients’ idea that the eye’s pupil is apple-shaped and that eyes are particularly precious.
Shakespeare used the phrase in A Midsummer Night’s Dream, 1600:
Flower of this purple dye,
Hit with Cupid’s archery,
Sink in apple of his eye
It also appears several times in the Bible; for example, in Deuteronomy 32:10 (King James Version, 1611)
He found him in a desert land, and in the waste howling wilderness; he led him about, he instructed him, he kept him as the apple of his eye.
and in Zechariah 2:8:
“For thus saith the LORD of hosts; After the glory hath he sent me unto the nations which spoiled you: for he that toucheth you toucheth the apple of his eye.”
The phrase was known from those early sources but became more widely used in the general population when Sir Walter Scott included it in the popular novel Old Mortality, 1816:
“Poor Richard was to me as an eldest son, the apple of my eye.”