What lies at the origins of major wars? I argue that major wars are caused by the attempts of great powers to escape their encirclement, that is, a two-front war problem. To explain the causal mechanism that links encirclement to major war, I identify an intervening variable: the increase in the invasion ability of the immediate rival. This outcome unfolds in a three-step process: double security dilemma, war initiation, and war contagion. Encirclement is a geographic variable that occurs in presence of one or two great powers (surrounding great powers) on two different borders of the encircled great power. The two front-war problem triggers a double security dilemma (step 1) for the encircled great power, which has to disperse its army to secure its borders. The surrounding great powers do not always have the operational capability to initiate a two-front war (latent encirclement) but, when they increase their invasion ability (actualized encirclement), the encircled great power attacks (war initiation, step 2). The other great powers intervene due to the rival-based network of alliances for preventing their respective immediate rival from increasing its invasion ability (war contagion, step 3). Combining archival work and historiographical analysis, I assess my theory in the three major wars: the Italian Wars, the Thirty Years' War, and World War I. This dissertation provides ample support to the claim that major wars are often caused by a great power that has the limited goal of eliminating its two-front war problem. These findings have important implications for future major wars, since I anticipate that China will likely face the encirclement of India and Russia.