Some pallets are treated with chemicals, but many are heat treated.
With chemical treated pallets, the wood is fumigated with methyl bromide (pesticide). Pallets treated via this method bear the initials MB near the IPPC logo. (International Plant Protection Convention). You would not want to use these under any circumstances near bees or other livestock.
With heat treated pallets the wood is heated to achieve a minimum core temperature of 56 °C (132.8 °F) for at least 30 minutes. Pallets treated via this method bear the initials HT near the IPPC logo.
Treated wood pallets must be stamped on two opposite sides indicating either HT for heat treated or MB for methyl bromide treatment.