Infections with hepatitis C virus (HCV) and, possibly, hepatitis B virus (HBV) are associated with an increased risk of non-Hodgkin's lymphoma (NHL) in the general population, but little information is available on the relationship between hepatitis viruses and NHL among people with HIV (PHIV). We conducted a matched case-control study nested in the Swiss HIV Cohort Study (SHCS). Two hundred and ninety-eight NHL cases and 889 control subjects were matched by SHCS centre, gender, age group, CD4+ count at enrollment, and length of follow-up. Odds ratios (OR) and corresponding 95% confidence intervals (CI) were computed using logistic regression to evaluate the association between NHL and seropositivity for antibodies against HCV (anti-HCV) and hepatitis B core antigen (anti-HBc), and for hepatitis B surface antigen (HBsAg). Anti-HCV was not associated with increased NHL risk overall (OR = 1.05; 95% CI: 0.63-1.75), or in different strata of CD4+ count, age or gender. Only among men having sex with men was an association with anti-HCV found (OR = 2.37; 95% CI: 1.03-5.43). No relationships between NHL risk and anti-HBc or HBsAg emerged. Coinfection with HIV and HCV or HBV did not increase NHL risk compared to HIV alone in the SHCS.