Modafinil is a prescription medication primarily used to promote wakefulness in individuals suffering from sleep disorders such as narcolepsy, sleep apnea, and shift work sleep disorder. It works by influencing neurotransmitters in the brain, helping to improve alertness, reduce excessive daytime sleepiness, and enhance focus.