Three striking features about both interstate and civil war are (1) there are often periods of persistent fighting, (2) fighting commonly ends in negotiated settlements as well as in militarily decisive outcomes, and (3) fighting sometimes recurs. This article links these features to shifts in the distribution of power and to the fact that one of the functions of fighting is to forestall adverse shifts. The analysis centers on a simple model of state consolidation. The equilibrium displays these features: Fighting occurs when the distribution of power is shifting rapidly. The factions avoid fighting and cut deals when the distribution of power shifts slowly or is stable. Fighting resumes if the distribution of power again begins to shift rapidly. The analysis also shows that state consolidation can occur without fighting if the process is sufficiently slow. Fighting now rather than later can also reduce the total cost of fighting.