Parents of many species care for their offspring by protecting them from a wide range of environmental hazards, including desiccation, food shortages, predators, competitors, and parasites and pathogens. Currently, little is known about the mechanisms and fitness consequences of parental defences against bacterial pathogens and competitors. Here, we combine approaches from microbiology and behavioural ecology to investigate the role and mechanistic basis of antibacterial secretions applied to carcasses by parents of the burying beetle Nicrophorus vespilloides. This species rears its larvae on vertebrate carcasses, where larvae suffer significant fitness costs due to competition with bacterial decomposers. We first confirm that anal secretions produced by parents are potently bactericidal and that their effects are specific to gram-positive bacteria. Next, we identify the source of bacterial killing as a secreted lysozyme and show that its concentration changes throughout the breeding cycle. Finally, we show that secreted lysozyme is crucial for larval development, increasing survival by nearly two-fold compared to offspring reared in its absence. These results demonstrate for the first time that anal secretions applied to carrion is a form of parental care and expand the mechanistic repertoire of defences used by parent insects to protect dependent offspring from microbial threats.