BACKGROUND: In patients with mild gallstone pancreatitis, cholecystectomy during the same hospital admission might reduce the risk of recurrent gallstone-related complications, compared with the more commonly used strategy of interval cholecystectomy. However, evidence to support same-admission cholecystectomy is poor, and concerns exist about an increased risk of cholecystectomy-related complications with this approach. In this study, we aimed to compare same-admission and interval cholecystectomy, with the hypothesis that same-admission cholecystectomy would reduce the risk of recurrent gallstone-related complications without increasing the difficulty of surgery. METHODS: For this multicentre, parallel-group, assessor-masked, randomised controlled superiority trial, inpatients recovering from mild gallstone pancreatitis at 23 hospitals in the Netherlands (with hospital discharge foreseen within 48 h) were assessed for eligibility. Adult patients (aged >/=18 years) were eligible for randomisation if they had a serum C-reactive protein concentration less than 100 mg/L, no need for opioid analgesics, and could tolerate a normal oral diet. Patients with American Society of Anesthesiologists (ASA) class III physical status who were older than 75 years of age, all ASA class IV patients, those with chronic pancreatitis, and those with ongoing alcohol misuse were excluded. A central study coordinator randomly assigned eligible patients (1:1) by computer-based randomisation, with varying block sizes of two and four patients, to cholecystectomy within 3 days of randomisation (same-admission cholecystectomy) or to discharge and cholecystectomy 25-30 days after randomisation (interval cholecystectomy). Randomisation was stratified by centre and by whether or not endoscopic sphincterotomy had been done. Neither investigators nor participants were masked to group assignment. The primary endpoint was a composite of readmission for recurrent gallstone-related complications (pancreatitis, cholangitis, cholecystitis, choledocholithiasis needing endoscopic intervention, or gallstone colic) or mortality within 6 months after randomisation, analysed by intention to treat. The trial was designed to reduce the incidence of the primary endpoint from 8% in the interval group to 1% in the same-admission group. Safety endpoints included bile duct leakage and other complications necessitating re-intervention. This trial is registered with Current Controlled Trials, number ISRCTN72764151, and is complete. FINDINGS: Between Dec 22, 2010, and Aug 19, 2013, 266 inpatients from 23 hospitals in the Netherlands were randomly assigned to interval cholecystectomy (n=137) or same-admission cholecystectomy (n=129). One patient from each group was excluded from the final analyses, because of an incorrect diagnosis of pancreatitis in one patient (in the interval group) and discontinued follow-up in the other (in the same-admission group). The primary endpoint occurred in 23 (17%) of 136 patients in the interval group and in six (5%) of 128 patients in the same-admission group (risk ratio 0.28, 95% CI 0.12-0.66; p=0.002). Safety endpoints occurred in four patients: one case of bile duct leakage and one case of postoperative bleeding in each group. All of these were serious adverse events and were judged to be treatment related, but none led to death. INTERPRETATION: Compared with interval cholecystectomy, same-admission cholecystectomy reduced the rate of recurrent gallstone-related complications in patients with mild gallstone pancreatitis, with a very low risk of cholecystectomy-related complications. FUNDING: Dutch Digestive Disease Foundation.