Many literature reports revealed the anticancer activity of pyridine and thiazole derivatives, especially in lung cancer. Therefore, a new series of thiazolyl pyridines linked with thiophene moiety via hydrazone group was prepared by one-pot multi-component reaction of (E)-1-(4-methyl-2-(2-(1-(thiophen-2-yl)ethylidene)hydrazinyl)thiazol-5-yl)ethanone with benzaldehyde derivatives and malononitrile in a good yield. Then, compound5and the thiazolyl pyridines were investigated for their in vitro anticancer activity against lung cancer (A549) cell line using MTT assay compared to doxorubicin as a reference drug. The structure of all the newly synthesized compounds was established based on spectroscopic data and elemental analyses. For better insight to investigate their mechanism of action on A549 cell line, docking studies were performed, targeting epidermal growth factor receptor (EGFR) tyrosine kinase. The results obtained revealed that the tested compounds displayed excellent anticancer activities against lung cancer cell line except8cand8fcompared to reference drug. Based on the data obtained, it can be inferred that the novel compounds, as well as their key intermediate, compound5, demonstrated potent anticancer activity against lung carcinoma by inhibiting EGFR.