Alprazolam is the generic version of Xanax/Tafil. It is used to treat anxiety disorders and panic attacks. Alprazolam is in a class of medications called benzodiazepines. It works by decreasing abnormal excitement in the brain.