In spite of our best efforts at cleaning the trash cans, policing the dog yard, and general sanitation, there are flies. Here's one on a marguerite daisy. This one is a green bottle flies (likely Phaenicia sericata). She and her fellows are noted for their taste for dog feces. They lay their eggs in freshly dead animals, or alternately, garbage containing dead meat or rotting vegetable matter. Paradoxically, I often find them resting, or sitting, or sunning, or hanging out on pretty flowers or nice clean, growing plants. During the late morning they are more active and just touch down for a bit, then fly off. But as the afternoon gets on and the sun starts to go down, they get sluggish. They resemble chickens going to roost, usually remain quite still, and require moderate molestation before they fly off of their chosen perch.
Here's another green bottle fly on a salvia plant.
If you look closely at second photo you'll see there's a green lynx spider lurking just out of focus to the left of the fly. We all know that spiders eat flies, and there's a good chance if you're a fly loafing on a flower you'll get picked off by one of the many species of spider that hunts among flowers and growing plants. So, why do these flies choose to rest in prime spider habitat instead of, say, on dog poop?
I read somewhere "the way you can tell there is no god is There Are Flies." Maybe the corollary to that could be "the way you can tell there is a god is There Are Spiders".