The aim of this case-control study was to evaluate whether 47 single-nucleotide polymorphisms (SNPs) in steroid hormone-related genes are associated with the risk of RA and anti-TNF drug response. We conducted a case-control study in 3 European populations including 2936 RA patients and 2197 healthy controls. Of those, a total of 1985 RA patients were treated with anti-TNF blockers. The association of potentially interesting markers in the discovery population was validated through meta-analysis with data from DREAM and DANBIO registries. Although none of the selected variants had a relevant role in modulating RA risk, the meta-analysis of the linear regression data with those from the DREAM and DANBIO registries showed a significant correlation of the CYP3A4rs11773597 and CYP2C9rs1799853 variants with changes in DAS28 after the administration of anti-TNF drugs (P = 0.00074 and P = 0.006, respectively). An overall haplotype analysis also showed that the ESR2GGG haplotype significantly associated with a reduced chance of having poor response to anti-TNF drugs (P = 0.0009). Finally, a ROC curve analysis confirmed that a model built with eight steroid hormone-related variants significantly improved the ability to predict drug response compared with the reference model including demographic and clinical variables (AUC = 0.633 vs. AUC = 0.556; PLR_test = 1.52 × 10-6). These data together with those reporting that the CYP3A4 and ESR2 SNPs correlate with the expression of TRIM4 and ESR2 mRNAs in PBMCs (ranging from P = 1.98 × 10-6 to P = 2.0 × 10-35), and that the CYP2C9rs1799853 SNP modulates the efficiency of multiple drugs, suggest that steroid hormone-related genes may have a role in determining the response to anti-TNF drugs.KEY POINTS• Polymorphisms within the CYP3A4 and CYP2C9 loci correlate with changes in DAS28 after treatment with anti-TNF drugs.• A haplotype including eQTL SNPs within the ESR2 gene associates with better response to anti-TNF drugs.• A genetic model built with eight steroid hormone-related variants significantly improved the ability to predict drug response.