The objectives of this study were to investigate the prevalence of gastrointestinal nematodes (GIN) among cattle in Sharkia Governate, Egypt and to determine the efficacy of allicin as a treatment for GIN infection. Fecal samples (n = 113) were collected randomly from cattle at different localities in Sharkia Governate between September 2016 and August 2018. Samples were then examined parasitologically. Overall, GIN were found in 21 (18.6%) of the samples, the highest GIN prevalence was observed in winter (25.6%), while the lowest prevalence was in summer (10.3%). Adult cattle (42.9%) showed higher GIN infection than young calves (23.8%). Further, most of the infected cattle (92.4%) showed a light intensity of infection with GIN. The coproculture of infected fecal samples reveled that, 15 (71.4%) samples have single infection and 6 (28.6%) samples have mixed infection and Trichostrongylus spp. (41.9%) were the most frequently observed GIN, followed by Strongyloides spp. (35.2%), whereas, Cooperia spp. (8.7%) was the less frequently observed GIN. No significant difference (P = 0.78) was observed between using albendazole and allicin for treatment of GIN in cattle. The current study provides new and updated results that may help in the effort to control GIN. Also, this study shows that allicin could be used for treatment and control of GIN in cattle. However, further investigations in the efficacy of allicin in treatment of GIN in cattle and actual dose, are warranted.