The length of time any illicit or prescribed drugs stay in your system will vary. In large part, it depends on your physiological makeup (e.g., your physical height, weight, your amount of body fat, your age, current state of health, whether or not you exercise mildly-aggressively-or at all). Whether or not you are undergoing any degree of stress (i.e., your "state of mind") at the time you ingest drugs can play a part in how long drugs stay in your system, as well.
Other considerations include your frequency of use (once per week? twice a day?), the quantity of drug you used each time, and the length of time of your consistent drug-use prior to your drug test. Even the quality ("potency") of the drug you ingest determines how long the drugs stay in your system and will be detectable when your urine is analyzed (tested) at the lab.
However, the information below can used to estimate the approximate length of time specific drugs will be detectable in your body. Generally, taking a drug test within the time-frames indicated will likely mean the laboratory will find your test result is POSITIVE!
Alcohol (Beer, Booze, Hooch, Liquor, Wine), 1 hour to perhaps 10 or 12 hours
Amphetamines (Biphetamine, Black Beauties, Crosses, Dexedrine, Hearts), 1-2 days
Anabolic steroids (Stanzolol, Stanazolol, Nandrolene; Steroids, Roids, Juice), oral- up to 3 weeks; injected- up to 3-6 months and more
Barbiturates (Amytal, Nembutal, Seconal, Phenobarbital; Barbs), 2-3 days
Benzodiazepines (e.g., Ativan, Halcion, Librium, Rohypnol, Valium; Roofies, Tranks, Xanax), most, 2-3 days; a few, 4-8 days
Cocaine (Candy, Coke, Crack, Flake, Rocks, Snow, Whitecoat), 1-2 days
Codeine (e.g., Fiorinal w/codeine, Robitussin A-C, Empirin w/codeine, Tylenol w/codeine, 1-2 days
GHB (G, Grievous Bodily Harm, Goob, Liquid Ecstasy, Liquid X), 1-2 days
Heroin (Horse, Smack), 1-2 days
Inhalants, just a few hours
Ketamine (K, Kit Kat, Special K, Vitamin K), 2-4 days
LSD (Acid, Blotter, Microdot, Yellow sunshine), a few hours or up to 5 days
Marijuana (Bud, Blunt, Grass, Herb, Pot, Reefer, Sinsemilla, Smoke, Weed), 2-5 days (the daily, heavy user can sometimes be detected up to 30+ days)
MDMA (Ecstasy), 1-5 days
Methadone, 1-7 days
Methamphetamines (Crank, Crystal, Desoxyn, Glass, Ice, Speed), 2-4 days
Methaqualone (Ludes, Quaaludes), 10-15 days
Nicotine (Cigarettes, Cigars, Habitrol patch, Nicorette gum, Nicotrol spray, Prostep patch; Smokeless tobacco, Snuff, Spit tobacco), 1-2 days
Opiates (i.e., Opium: China, Dreams, Laudanum, Paregoric; Dover's Powder), 1-2 days
Oxycodone (OxyContin, Percolone, Roxicodone), 1-2 days
PCP (Angel Dust, Boat, Hog, Love Boat), 1-8 days
NOTE: For chronic drug users, drugs (other than alcohol) can be retained in the system much longer after their last use. For instance, marijuana and PCP stay in your system and can be detected for up to 30+ days after lengthy periods of heavy use.