Gabapentin is a medication that is primarily used to treat seizures and nerve pain. It belongs to a class of drugs known as anticonvulsants or anti-epileptics. In addition to its role in epilepsy and nerve pain, gabapentin is also sometimes prescribed off-label for other conditions such as restless leg syndrome, anxiety, insomnia, hot flashes in menopause, and alcohol withdrawal. It works by increasing the neurotransmitter in the brain.