Xanax contains alprazolam, a medication that works by enhancing the activity of gamma-aminobutyric acid (GABA), a naturally occurring chemical messenger in the brain. This activity helps reduce excessive nervous system activity and produces a calming effect.