In conclusion, our study identified significant associations between the germline genetic variations of the overall EGFR signaling pathway and several individual genes and the risk of GC, as well as individual genes and the risk of ESCC, suggesting a possible role for EGFR pathway genes in the development of UGI cancers. This evidence concerns the gene EGFR and esophageal squamous cell carcinoma.