Raman spectroscopy is an optical vibrational technology capable of probing biomolecular changes of tissue associated with cancer transformation. This study aimed to characterize in vivo Raman spectroscopic properties of tissues belonging to different anatomical regions in the upper gastrointestinal (GI) tract and explore the implications for early detection of neoplastic lesions during clinical gastroscopy. A novel fiber-optic Raman endoscopy technique was utilized for real-time in vivo tissue Raman measurements of normal esophageal (distal, middle, and proximal), gastric (antrum, body, and cardia) as well as cancerous esophagous and gastric tissues from 107 patients who underwent endoscopic examinations. The non-negativity-constrained least squares minimization coupled with a reference database of Raman active biochemicals (i.e., actin, histones, collagen, DNA, and triolein) was employed for semiquantitative biomolecular modeling of tissue constituents in the upper GI. A total of 1189 in vivo Raman spectra were acquired from different locations in the upper GI. The Raman spectra among the distal, middle, and proximal sites of the esophagus showed no significant interanatomical variability. The interanatomical variability of Raman spectra among normal gastric tissue (antrum, body, and cardia) was subtle compared to cancerous tissue transformation, whereas biomolecular modeling revealed significant differences between the two organs, particularly in the gastroesophageal junction associated with proteins, DNA, and lipids. Cancerous tissues can be identified across interanatomical regions with accuracies of 89.3% [sensitivity of 92.6% (162/175); specificity of 88.6% (665/751)], and of 94.7% [sensitivity of 90.9% (30/33); specificity of 93.9% (216/230)] in the gastric and esophagus, respectively, using partial least squares-discriminant analysis together with the leave-one tissue site-out, cross validation.