Background Whether concomitant therapy is superior to bismuth quadruple therapy or 14-day triple therapy for the first-line treatment of Helicobacter pylori infection remains poorly understood. We aimed to compare the efficacy and safety of 10-day concomitant therapy, 10-day bismuth quadruple therapy, and 14-day triple therapy in the first-line treatment of H pylori. Methods In this multicentre, open-label, randomised trial, we recruited adult patients (aged >20 years) with H pylori infection from nine medical centres in Taiwan. Patients who had at least two positive tests from the rapid urease test, histology, culture, or serology or who had a single positive 13C-urea breath test for gastric cancer screening were eligible for enrolment. Patients were randomly assigned (1:1:1) to either concomitant therapy (lansoprazole 30 mg, amoxicillin 1 g, clarithromycin 500 mg, and metronidazole 500 mg, all given twice daily) for 10 days; bismuth quadruple therapy (bismuth tripotassium dicitrate 300 mg four times a day, lansoprazole 30 mg twice daily, tetracycline 500 mg four times a day, and metronidazole 500 mg three times a day) for 10 days; or triple therapy (lansoprazole 30 mg, amoxicillin 1 g, and clarithromycin 500 mg, all given twice daily) for 14 days. A computer-generated permuted block randomisation sequence with a block size of 6 was used for randomisation, and the sequence was concealed in an opaque envelope until the intervention was assigned. Investigators were masked to treatment allocation. The primary outcome was the eradication frequency of H pylori with first-line therapy assessed in the intention-to-treat population. This trial is registered with ClinicalTrials.gov, number NCT01906879. Findings Between July 17, 2013, and April 20, 2016, 5454 patients were screened for eligibility. Of these, 1620 patients were randomly assigned in this study. The eradication frequencies were 90·4% (488/540 [95% CI 87·6–92·6]) for 10-day bismuth quadruple therapy, 85·9% (464/540 [82·7–88·6]) for 10-day concomitant therapy, and 83·7% (452/540 [80·4–86·6]) for 14-day triple therapy in the intention-to-treat analysis. 10-day bismuth quadruple therapy was superior to 14-day triple therapy (difference 6·7% [95% CI 2·7–10·7, p=0·001), but not 10-day concomitant therapy. 10-day concomitant therapy was not superior to 14-day triple therapy. The frequency of adverse events was 67% (358/533) in patients treated with 10-day bismuth quadruple therapy, 58% (309/535) in patients treated with 10-day concomitant therapy, and 47% (252/535) in patients treated with 14-day triple therapy. Interpretation Bismuth quadruple therapy is preferable to 14-day triple therapy in the first-line treatment in the face of rising prevalence of clarithromycin resistance. Concomitant therapy given for 10 days might not be optimum and a longer treatment length should be considered. Funding National Taiwan University Hospital and Ministry of Science and Technology of Taiwan.