Urine drug tests can detect drugs taken up to seven days ago or even longer, depending on frequency of drug use. Hair drug testing can detect drugs taken up to 90 days ago.