The chemical composition of the essential oil (EO) from fresh cocklebur (Xanthium strumarium L.) leaves was investigated by GC-MS. The antimicrobial activity of the EO was tested against Gram-positive and Gram-negative bacteria and fungi. Scolicidal activity was assayed against Echinococcus granulosus protoscolices. In total, 34 compounds were identified, accounting for 98.96% of the EO. The main compounds in the EO were cis-β-guaiene (34.2%), limonene (20.3%), borneol (11.6%), bornyl acetate (4.5%), β-cubebene (3.8%), sabinene (3.6%), phytol (3.1%), β-selinene (2.8%), camphene (2.2%), α-cubebene (2.4%), β-caryophyllene (1.9%), α-pinene (1.8%) and xanthinin (1.04%). The antibacterial and antifungal screening of the EO showed that all assayed concentrations significantly inhibited the growth of Staphylococcus aureus, Bacillus subtilis, Klebsiella pneumoniae, Pseudomonas aeruginosa, Candida albicans and Aspergillus niger (MIC = 0.5 ± 0.1, 1.3 ± 0.0, 4.8 ± 0.0, 20.5 ± 0.3, 55.2 ± 0.0 and 34.3 ± 0.0 µg/mL, respectively). The scolicidal assay indicated that the EO exhibited a significant activity against E. granulosus protoscolices. To the best of our knowledge, this is the first report on the scolicidal activity of X. strumarium. Because of the emergence of antimicrobial drug resistance, the study of new effective natural chemotherapeutic agents, such as the X. strumarium EO, possibly with low side effects, represents a very promising approach in biomedical research.