Contamination of peanuts with mycotoxins, particularly aflatoxins, is a worldwide problem that affects both food safety and agricultural economies. Most countries have adopted regulations that limit the quantity of aflatoxins in food and feed to 20 microg kg(-1) or less; however, environmental conditions in most of the world where peanuts are produced and stored often make it difficult or impossible to attain such low concentrations. In addition to aflatoxins, peanuts are often contaminated with cyclopiazonic acid (CPA). Both mycotoxins are produced by Aspergillus flavus, a ubiquitous fungus that can infect and grow in peanuts under both pre- and post-harvest conditions. Management of mycotoxin contamination in peanuts generally involves removal of high-risk components from shelled lots or the removal of individual, highly contaminated nuts. This is accomplished by various processes such as screening, kernel sizing, electronic colour sorting, hand sorting, and blanching followed by electronic colour sorting. Recently, biological control technology has been developed that prevents much of the contamination that might otherwise occur. Biocontrol is based on competitive exclusion whereby a dominant population of a non-toxigenic strain of A. flavus is established in the soil before peanuts are subjected to conditions favouring contamination. The applied strain competes with toxigenic strains for infection sites, resulting in significantly reduced concentrations of aflatoxins in peanuts. Monitoring of the first commercial use of the technology showed that aflatoxins were reduced by an average of 85% in farmers' stock peanuts and by as much as 98% in shelled, edible grade peanuts.