The story
From Easter + egg. Cognate with German Low German Ooosterei (“Easter egg”), Middle High German ōsterei ("Easter egg"; > modern German Osterei). So called because eggs would be eaten during Easter to break the fasting during Lent. (No eggs, dairy, meat except fish, lard, or foods containing these ingredients could be eaten during Lent.) The computing sense is from the early 1980s, popularized by the video game Adventure.
First known use, by meaning
- from 1980s An undocumented function hidden in a program or video game, typically triggered by a particular input sequence or combination of keystrokes.
Etymology from Wiktionary, CC BY-SA 4.0.