Diazepam is used to treat anxiety, muscle spasms, and alcohol withdrawal. The injection form is used when prompt relief is desired or when the medication cannot be taken by mouth.This medication is also used for the short-term treatment of serious seizures that do not stop (status epilepticus). It is not for ongoing daily use to prevent seizures.Diazepam is also used before a surgery or procedure to cause drowsiness, decrease anxiety, and to help the patient forget what happened during the surgery/procedure.This medication works by calming the brain and nerves. Diazepam belongs to a class of drugs known as benzodiazepines.