Methadone is a synthetic opioid. It is used as an analgesic. Besides relieving pain, it is also used to treat addiction to certain narcotics, and some illegal drugs.