Continuous usage of synthetic chemotherapeutic drugs causes adverse effects, which prompted for the development of alternative therapeutics for gastric cancer from natural source. This study was carried out with a specific aim to screen gastroprotective compounds from the fruits of Syzygium alternifolium (Myrtaceae). Three flavonoids, namely, 1) 5-hydroxy-7,4′-dimethoxy-6,8-di-C-methylflavone, 2) kaempferol-3-O- β- d-glucopyranoside, and 3) kaempferol-3-O- α- l-rhamnopyranoside were isolated from the above medicinal plant by employing silica gel column chromatography and are characterized by NMR techniques. Antigastric cancer activity of these flavonoids was examined on AGS cell lines followed by cell cycle progression assay. In addition, pharmacophore-based screening and molecular dynamics of protein–ligand complex were carried out to identify potent scaffolds. The results showed that compounds 2 and 3 exhibited significant cytotoxic effect, whereas compound 1 showed moderate effect on AGS cells by inhibiting G2/M phase of cell cycle. Molecular docking analysis revealed that compound 2 has higher binding energies on human growth factor receptor-2 (HER2). The constructed pharmacophore models reveal that the compounds have more number of H-bond Acc/Don features which contribute to the inhibition of HER2 activity. By selecting these features, 34 hits were retrieved using the query compound 2. Molecular dynamic simulations (MDS) of protein–ligand complexes demonstrated conspicuous inhibition of HER2 as evidenced by dynamic trajectory analysis. Based on these results, the compound ZINC67903192 was identified as promising HER2 inhibitor against gastric cancer. The present work provides a basis for the discovery a new class of scaffolds from natural products for gastric carcinoma.