Using flashy or moving objects to deter birds from defecating on your deck or patio is an effective method. Windchimes made of metal, metallic streamers, and even old CDs can be used as decorative elements on walls.
When they flap their wings in response to the wind, birds will experience fear. To make your yard appear less attractive, you should avoid keeping any food or water out in the open.