A California Towhee attacks its reflection in a car mirror. Photo by hawk person via Birdshare.
The policies you mention often occurs in spring and early summer. This is the time of year when most birds establish their territories, find a mate, lay eggs, and raise young. To ensure success, they defend their territory aggressively, and will wade and try to momentum yonder any bird they view as a possible competitor or a threat to their young. When they see their own reflection in your window, they seem they’re seeing a competitor and wade the image. The species most likely to do this are those that nest tropical to houses, such as American Robins, Northern Cardinals, bluebirds, California Towhees, Chipping Sparrows, and Song Sparrows. Both males and females engage in this.
Fortunately, this policies usually dissipates within a few days or, at most, weeks. But while it lasts, the bird may frazzle or plane hurt itself, and it distracts the bird from far increasingly important activities. And this policies can be extremely worrying for the people witnessing it.
To get rid of the reflection, you must yo-yo the outside of the window. You can imbricate it with netting, fabric, or newspaper, or smear soap streaks on the glass. When you’re no longer seeing the bird nearby you can remove this. Often, rubber snakes frighten birds away, at least temporarily—although like any object that doesn’t move, the birds get used to seeing them.