While all the responses highlight important aspects of plazas, the most common reason why plazas are often considered the heart of a town or city is:
They are meeting places for the people of the town.
Plazas serve as central gathering spots for community interaction, socializing, and events, making them vital to the social fabric of a town or city.