CDKL5 deficiency disorder (CDD) is a rare, X-linked, developmental and epileptic encephalopathy characterised by severe global developmental impairment and seizures that can begin in the first few months after birth and are often treatment refractory. Ganaxolone, an investigational neuroactive steroid, reduced seizure frequency in an open-label, phase 2 trial that included patients with CDD. We aimed to further assess the efficacy and safety of ganaxolone in patients with CDD-associated refractory epilepsy. In the double-blind phase of this randomised, placebo-controlled, phase 3 trial, done at 39 outpatient clinics in eight countries (Australia, France, Israel, Italy, Poland, Russia, the UK, and the USA), patients were eligible if they were aged 2-21 years with a pathogenic or probably pathogenic CDKL5 variant and at least 16 major motor seizures (defined as bilateral tonic, generalised tonic-clonic, bilateral clonic, atonic, or focal to bilateral tonic-clonic) per 28 days in each 4-week period of an 8-week historical period. After a 6-week prospective baseline period, patients were randomly assigned (1:1) via an interactive web response system to receive either enteral adjunctive ganaxolone or matching enteral adjunctive placebo (maximum dose 63 mg/kg per day for patients weighing ≤28 kg or 1800 mg/day for patients weighing >28 kg) for 17 weeks. Patients, caregivers, investigators (including those analysing data), trial staff, and the sponsor (other than the investigational product manager) were masked to treatment allocation. The primary efficacy endpoint was percentage change in median 28-day major motor seizure frequency from the baseline period to the 17-week double-blind phase and was analysed (using a Wilcoxon-rank sum test) in all patients who received at least one dose of trial treatment and for whom baseline data were available. Safety (compared descriptively across groups) was analysed in all patients who received at least one dose of trial treatment. This study is registered with ClinicalTrials.gov, NCT03572933, and the open-label extension phase is ongoing. Between June 25, 2018, and July 2, 2020, 114 patients were screened for eligibility, of whom 101 (median age 6 years [IQR 3 to 10]) were randomly assigned to receive either ganaxolone (n=50) or placebo (n=51). All patients received at least one dose of a study drug, but seizure frequency for one patient in the ganaxolone group was not recorded at baseline and so the primary endpoint was analysed in a population of 100 patients. There was a median percentage change in 28-day major motor seizure frequency of -30·7% (IQR -49·5 to -1·9) in the ganaxolone group and of -6·9% (-24·1 to 39·7) in the placebo group (p=0·0036). The Hodges-Lehmann estimate of median difference in responses to ganaxolone versus placebo was -27·1% (95% CI -47·9 to - 9·6). Treatment-emergent adverse events occurred in 43 (86%) of 50 patients in the ganaxolone group and in 45 (88%) of 51 patients in the placebo group. Somnolence, pyrexia, and upper respiratory tract infections occurred in at least 10% of patients in the ganaxolone group and more frequently than in the placebo group. Serious adverse events occurred in six (12%) patients in the ganaxolone group and in five (10%) patients in the placebo group. Two (4%) patients in the ganaxolone group and four (8%) patients in the placebo group discontinued the trial. There were no deaths in the double-blind phase. Ganaxolone significantly reduced the frequency of CDD-associated seizures compared with placebo and was generally well tolerated. Results from what is, to our knowledge, the first controlled trial in CDD suggest a potential treatment benefit for ganaxolone. Long-term treatment is being assessed in the ongoing open-label extension phase of this trial. Marinus Pharmaceuticals.