A number of prescription and over-the-counter medications can interfere with or cause loss of memory. Possible culprits include: antidepressants, antihistamines, anti-anxiety medications, muscle relaxants, tranquilizers, sleeping pills, and pain medications given after surgery. Alcohol, tobacco, or drug use.