Eyelid twitching or ticking occurs when the muscles in the eyelid contract involuntary and uncontrollably, causing the eye to blink abnormally.