The jus ad bellum – the international regime that governs cross-border force – is an enigma. The regime is foundational to the global order and has been remarkably resilient over time. And yet, it is deeply discordant, even incoherent, in its operation. A few use of force norms are settled and robust. Although states occasionally deviate from these norms, the deviations are widely viewed and treated as legal violations. Other use of force norms are noticeably more compromised. Operations that stray from these norms are still perceived to be unlawful, but such operations might be tolerated or even supported in practice. Still other norms are highly contested. The substantive content of the norms is so openly and heatedly debated that the credibility of the entire regime has been called into question. This article presents a theory to explain why the regime on the use of force operates as it does. We argue that the regime is best understood as a site of ongoing contestation and compromise between two visions of the legal order – two ‘codes’. Each code has its own substantive policies, decision-making processes, and key advocates. The way in which advocates of the two codes interact in any given context determines whether and how specific use of force norms are articulated, invoked or applied.