Background: Antibiotic-resistant gonorrhoea represents a global public health threat, and new therapies are needed. We aimed to compare the efficacy and safety of solithromycin, a fourth generation macrolide, with ceftriaxone plus azithromycin for the treatment of gonorrhoea. Methods: We did an open-label, multicentre, non-inferiority trial of patients aged 15 years or older with uncomplicated untreated genital gonorrhoea at two sites in Australia and one site in the USA. Patients were randomly assigned (1:1) to receive single dose oral solithromycin 1000 mg or intramuscular ceftriaxone 500 mg plus oral azithromycin 1000 mg. Neisseria gonorrhoeae cultures were obtained at baseline and test of cure (day 7 ± 2). The primary outcome was the proportion of patients with eradication of genital N gonorrhoeae based on culture at test of cure, assessed in the microbiological intention-to-treat (mITT) population, which included all randomly assigned patients who received any dose of study drug and had a positive genital culture for N gonorrhoeae at baseline. Non-inferiority of solithromycin was to be concluded if the lower limit of the 95% CI for the between-group differences was greater than −10%. Safety was analysed in all patients who received any dose of study drug. This trial is registered with ClinicalTrials.gov, number NCT02210325. Findings: Between Sept 3, 2014, and Aug 27, 2015, 262 patients were randomly assigned and 261 received treatment (130 in the solithromycin group and 131 in the ceftriaxone plus azithromycin group). In the mITT population, 99 (80%) of 123 patients in the solithromycin group and 109 (84%) of 129 patients in the ceftriaxone plus azithromycin group had N gonorrhoeae eradication at test of cure (difference −4·0%, 95% CI −13·6 to 5·5), thus solithromycin did not meet the criterion for non-inferiority at the prespecified −10% margin. The frequency of adverse events was higher in the solithromycin group than the ceftriaxone plus azithromycin group (69 [53%] of 130 patients vs 45 [34%] of 131 patients), the most common of which were diarrhoea (31 [24%] of 130 patients vs 20 [15%] of 131 patients), and nausea (27 [21%] of 130 patients vs 15 [11%] of 131 patients). Interpretation: Solithromycin as a single 1000 mg dose is not a suitable alternative to ceftriaxone plus azithromycin as first-line treatment for gonorrhoea. If insufficient duration of solithromycin exposure at the infection site in a subset of individuals was the reason for treatment failures, this might be adequately addressed with dose adjustment. However, any further trials with longer dosing need to consider the potential risk of gastrointestinal effects and liver enzyme elevations. Funding: Cempra Pharmaceuticals.