Background Most previous studies about drug use in the elderly population have either investigated drug use in institutions or in the community-dwelling setting. Hence, very few studies have compared drug use in institutionalized and community-dwelling elderly, maybe because of a lack of sufficiently large databases. Objective The aim of the study was to investigate differences in drug use patterns between community-dwelling and institutionalized elderly, after adjustment for age, gender and number of other drugs (used as a proxy for overall co-morbidity). Methods We analysed data from individuals aged >= 65 years who filled at least one drug prescription between July and September 2008 and were consequently registered in the Swedish Prescribed Drug Register (n = 1,347,564; 1,260,843 community-dwelling and 86,721 institutionalized elderly). A list of current prescriptions was constructed for every individual on the arbitrarily chosen date 30 September 2008. Outcome measures were the 20 most common drug classes and the 20 most common individual drugs. Logistic regression analysis was used to investigate whether institutionalization was associated with use of these drugs, after adjustment for age, gender and number of other drugs. Results Institutionalized elderly were more likely than community-dwelling elderly to use antidepressants, laxatives, minor analgesics, opioids and hypnotics/sedatives, after adjustment for age, gender and number of other drugs. On the contrary, institutionalization was negatively associated with use of lipid modifying agents, angiotensin II antagonists, selective calcium channel blockers, beta-blocking agents and ACE inhibitors, after adjustment for age, gender and number of other drugs. Conclusions Our results indicate that institutionalized elderly are more likely than community-dwelling elderly to use psychotropics, analgesics and laxatives, but less likely to receive recommended cardiovascular drug therapy, which may indicate a need for implementation of evidencebased guidelines for drug treatment in this vulnerable group of elderly patients. Further research is needed to elucidate to what extent the differences in drug use between community-dwelling and institutionalized elderly are explained by different underlying disease patterns and by different prescribing traditions in the different settings.