Attracted by the scent of damaged carrot foliage, carrot flies lay their eggs in the soil around the carrot plants. The larvae feed on the carrots, leaving tunnels and holes and causing leaf discolouration. Carrot flies frequently attack when the carrot crop is thinned, and they can follow the scent of the carrot foliage for miles. There are no approved insecticides effective on the carrot fly, so prevention is key.
Plan your gardening around the carrot fly's behavioural patterns. Carrot flies are known to attack twice a year, with the first attack occurring in late May and early June, and the second attack in August and September. Avoid sowing carrot seeds in your garden until at least late May so your carrot plants won't be ready to thin until after the initial infestation period. Additionally, you may want to consider the use of companion planting in your garden, especially if carrots won't be your only crop. Alternate rows of carrots with rows of onions or leeks, plants avoided by the carrot fly. Plant wormwood, sage or tansy around the carrot beds to mask the scent of the carrot plant.
When thinning time comes, wait until evening to thin your seedlings. Carrot flies are more active in the morning and afternoon. Destroy all thinned carrot plants. Carrot flies prefer to lay eggs in loose soil. After thinning, firm the soil around the plants. As your carrot plants mature, check regularly for leaf discolouration. Promptly remove any infested plants.
Barriers can be used to prevent carrot fly infestation. The scent of freshly mown grass is known to deter the carrot fly. Scatter fresh grass clippings between the carrot rows each time you mow your lawn. Despite their name, carrot flies actually can't fly very well. Enclose your carrot patch with a barrier wall that is at least 2 ½ feet tall. Carrot flies won't be able to fly up and over the wall, which can be made of strips of polythene or other materials. Alternatively, you can cover your entire carrot patch with horticultural fleece. Floating crop covers made of polyester or polypropylene are also available. In addition to preventing carrot flies, this fleece will provide higher soil temperatures and protect against heavy rain damage, potentially resulting in a more bountiful carrot harvest.
Fork through the soil of your carrot patch during the winter. Carrot flies can overwinter in the soil; forking exposes them to predators and frost. It is also a good practice to rotate crops in your garden each year to reduce other common garden pests and diseases in all your crops.