Before turning to plant extracts as the default solution to your arthropod irritants, bear in mind that some pure chemicals may be a bit less damaging than certain highly concentrated oils and extracts. After all, nightshade is a plant, too, and you don't want to spray that all over yourself or your pets. Specialty chemicals are a viable option regardless of your ecological leanings, so don't assume that "organic" means "harmless."
The simplest, greenest and most effective way to control fleas without harming the environment is to add a little bit of special dirt to your lawn. Diatomaceous earth (DE) looks like talcum powder, but it is in fact a fine dust made from the skeletons of diatom algae, a sort of free-floating coral. While harmless to humans, this substance coats any bug and embeds in its shell like a million tiny razor blades. After a while, the insect simply disintegrates and dies. Make sure to purchase the "food grade" DE sold at some pet stores, not the DE designed for pools.
True cinnamon oil contains a combination of cinnamaldehyde, which makes up approximately 90 percent of the oil by volume and gives cinnamon its flavor; eugenol, which is also found in cloves and is often used as a dental anesthetic; and anethole, which gives anise and black licorice its flavor. All three of these are fairly environmentally friendly, and they all kill bugs. However, many commercially available cinnamon oils contain only cinnamaldehyde, which kills fleas but not necessarily ticks. However, the smell burns the bugs' scent receptors and eyes, so it does tend to drive them away. Simply mix an ounce of cinnamon oil into a half-gallon of horticultural oil and spray it in an inconspicuous place to make sure the mixture won't burn your grass. Afterward, load the mixture into a sprayer and apply it to the lawn and other affected areas.
You might also want to consider several alternative compounds. They'll all control pests to some degree or another, but not all are completely compatible with all plants. Do your homework before spraying your lawn with any solution of castor oil, cedar oil, citric acid, citronella and citronella oil, cloves and clove oil, corn gluten meal, corn oil, cottonseed, garlic and garlic oil, geraniol, geranium oil, lauryl sulfate, lemongrass oil, linseed oil, malic acid, mint and mint oil, peppermint and peppermint oil, 2-phenylethyl propionate, potassium sorbate, putrescent whole egg solids, rosemary and rosemary oil, sesame and sesame oil, sodium chloride, sodium lauryl sulfate, soybean oil, thyme and thyme oil, white pepper or zinc metal strips.
Although it's considered fairly harmless for human beings and direct application to pets, inhaling food-grade DE probably isn't a good idea. Wear goggles and a mask when applying this fine powder to your lawn, and do your best to keep it out of your pet's eyes and nose. Essential oils such as those mentioned in Section 4 are fairly benign in low concentrations, but avoid using them on lawns if you have cats. Cats get into the grass and get the oils on their fur, then lick them off as they clean themselves. Not only are these oils an irritant for the cat, over time they can build up in the cat's system to cause serious health problems and possibly death. Don't use any chrysanthemum extracts; they can kill your pets, period.