In many cities and suburbs, the sound of street dogs barking at night is a common sight. Some people may find it upsetting 

When dogs bark, they attempt to keep possible threats, like other dogs or strange people, from entering their territory.  

Competition for limited resources can also lead to fights between street dogs, which makes them bark as a way to protect resources or show who is boss.

Loud noises, like car engines, honking, or people walking around, can make dogs bark because they think the noises are threats or problems.  

As a way to form social ties and make their presence known in the city, dogs may bark behind cars as a group activity.