Although the risk factors for acquiring infection by extended-spectrum beta-lactamase (ESBL)-producing bacteria have been investigated in hospitalized patients, such risk factors have not been defined in the community setting. In this study, clinical data from a total of 311 nonhospitalized patients with community-acquired urinary tract infection (128 with ESBL-positive strains and 183 with ESBL-negative strains) were obtained. According to a multivariate analysis, the following were identified as independent risk factors: previous hospitalization in the past 3 months (OR=8.95, 95%CI, 3.77-21.25), antibiotic treatment in the past 3 months (OR=3.23, 95%CI, 1.76-5.91), age over 60 years (OR=2.65, 95%CI, 1.45-4.83), diabetes (OR=2.57, 95%CI, 1.20-5.51), male gender (OR=2.47, 95%CI, 1.22-5.01), Klebsiella pneumoniae infection (OR=2.31, 95%CI, 1.17-4.54), previous use of third-generation cephalosporins (P=0.014, OR=15.8, 95%CI, 1.7-143), previous use of second-generation cephalosporins (P<0.0001, OR=10.1, 95%CI, 4.2-24), previous use of quinolones (P=0.001, OR=4.1, 95%CI, 1.8-9.0), and previous use of penicillin (P=0.003, OR=4.0, 95%CI, 1.6-9.0).