The Prophet ﷺ spent 13 years in Mecca enduring persecution without fighting. Fighting began only after he and his community had been driven out and attacked, and in the ten years in Medina, scholars estimate that all the battles together cost around a thousand lives or fewer on both sides.
The fuller answer
The Meccans tortured and killed early Muslims, boycotted the clan of the Prophet ﷺ for three years and plotted to kill him. After the migration to Medina, the battles of Badr, Uhud and the Trench were fought to defend the city. Where he could, he preferred treaties, as in the Treaty of Hudaybiyyah, and the conquest of Mecca took place almost without bloodshed, with a general pardon.
Critics point to the battles against Jewish tribes of Medina, such as Banu Qurayzah, which broke treaties during the siege. Muslims respond that these were in the context of treason during wartime and that the judgment was by a leader of their own allies according to their own law. The Prophet's overall life is seen by Muslims as a model of mercy, as the Quran describes him.
This answer follows the mainstream Sunni understanding and is general learning, not a fatwa. Where Muslims differ, the answer says so. Have a question of your own? Write to us.