BACKGROUND: Gastro-oesophageal reflux is a strong risk factor for oesophageal adenocarcinoma. Bile and pancreatic enzymes may be particularly carcinogenic. Cholecystectomy causes an increased gastric level of these constituents. A decreased risk of oesophageal adenocarcinoma has been observed in persons infected with cagA-positive Helicobacter pylori. There is a strong correlation between ulcer disease and Helicobacter pylori infection. The aim of this study was to determine whether previous cholecystectomy or peptic ulcer disease affects the risk of oesophageal carcinoma. METHODS: Data were collected as a nationwide population-based case-control study in Sweden between 1995 and 1997. Multivariate adjusted odds ratios (ORs) were calculated with logistic regression. RESULTS: There was no statistically significant association between cholecystectomy and the risk of oesophageal carcinoma. Among persons with previous peptic ulcer, the adjusted OR for oesophageal adenocarcinoma was below unity (OR = 0.6, 95 per cent confidence interval 0.3-1.1). The relative risk estimates for cardia adenocarcinoma and oesophageal squamous cell carcinoma were close to unity. CONCLUSION: Cholecystectomy, despite its effect on the composition of gastric juice, does not appear to increase the risk of adenocarcinoma of the oesophagus or gastric cardia. While the data do not contradict a protective effect of H. pylori, the results are also consistent with absence of such an effect.