Cordyceps militaris (CM), an entomopathogenic fungus belonging to the class ascomycetes, possesses various pharmacological activities, including cytotoxic effects, on various types of human tumor cells. The present study investigated the anti‑hepatocellular carcinoma (HCC) and anti‑breast cancer effects of CM in in vitro and in vivo models. CM aqueous extract reduced cell viability, suppressed cell proliferation, inhibited cell migration ability, caused the over-release of lactate dehydrogenase, induced mitochondrial dysfunction and enhanced apoptotic rates in MCF‑7 and HepG2 cells. The expression levels of cleaved poly (ADP ribose) polymerase and caspase‑3, biomarkers of apoptosis, were increased following treatment with CM aqueous extract for 24 h. Furthermore, in the MCF‑7 and HepG2 cells, enhanced levels of B cell‑associated X protein and cleaved caspase‑8 were observed in the CM‑treated cells. Finally, the antitumor activities of CM in HCC and breast cancer were also confirmed in MCF‑7‑ and HepG2‑xengraft nude mice models. Collectively, the data obtained in the present study suggested that the cytotoxic effects of CM aqueous extract on HCC and breast cancer are associated with the caspase‑dependent mitochondrial pathway.