Published in


Ur-Nammu and Hammurabi: Pre-Mosaic Codes of Law

The quest for human justice is as old as human civilization itself.

Statue of Moses holding the Ten Commandments in the Colonna dell’Immacolata, Rome
Statue of Moses holding the Ten Commandments in the Colonna dell’Immacolata, Rome

Few ancient codes of law have withstood the test of time. The Law of Moses, which has influenced much of Western culture and law and is still observed today by Jewish and Christian traditions, is a rare and notable exception.

Nevertheless, some of these ancient laws have been recently unearthed and preserved — laws far older than even the Hebrew Torah. These codes arose from the great civilizations of the Fertile Crescent, written by the mightiest leaders and reformers of their era.

Among these codes, there are two that set themselves apart from the rest for their quality of preservation: one penned by a Sumerian king who reunified Mesopotamia, the other authored by one of the most memorable Babylonian rulers in history.

These are the Codes of Ur-Nammu and Hammurabi.


By the end of the 22nd century BC, the ancient city of Ur — known for being the supposed birthplace of Abraham, the patriarch of Judaism, Christianity and Islam — had been subservient to several other Sumerian cities, such as Akkad, Lagash and Uruk.

It was at this time, however, that the city regained its prominence as the capital of the Neo-Sumerian Empire, a feat accomplished by none other than Ur-Nammu, a military officer.

After claiming Ur’s independence from neighboring Uruk, Ur-Nammu reigned supreme for eighteen years as the founder of the Third Dynasty of Ur. His burgeoning empire was expanded by notable military achievements, yet it was his code of law that brought much needed stability to the nascent dynasty.

The Code of Ur-Nammu was written and compiled either under the reign of Ur-Nammu himself or that of his son, Shulgi, whose rule surpassed his father’s, both in longevity and in depth of reformation. What remains of this code is an innovative list of casuistic laws presented in an “if…,then…” fashion, which became standard for subsequent Ancient Near Eastern legal codes.

The code’s content itself is groundbreaking, including penalties for charges of sexual offenses, manslaughter, perjury and murder. It also uses monetary compensation to punish physical assault and damage, rather than the retributory principle of lex talionis later employed by the Babylonian Empire.


Fast-forward about three centuries, and the Neo-Sumerian Empire was no more. Instead, it was Babylon who now rose to conquer Mesopotamia.

At the head of this expanding city-state was none other than Hammurabi, the sixth ruler of his lineage. An ingenious leader, Hammurabi transformed his small city-state into the First Babylonian Empire, conquering his way along the Euphrates and Tigris in his reign’s forty-year span. Along with it he developed a copious code, praised today as one of the most complete and well preserved ancient legal codes to have been discovered.

From its famous stone stela and several other sources found throughout the ages, the Code of Hammurabi is a testament to the king’s splendorous achievements as well as his rigorous judgment. It consists of a staggering number of 282 laws, following Ur-Nammu’s cause-and-effect pattern.

Much of the code deals primarily with contract laws, legal distinctions between freemen and slaves, and punishment of criminal offenses, ranging from perjury and defamation to theft and murder. Its employment of the “an eye for an eye” maxim is evident in the later part of the code, which deals mostly with physical assault, murder and insurrection.


Despite Ancient Mesopotamia having little-to-no direct impact in Western culture and society, its pre-Mosaic codes of law lay the foundations for much of Western law and religion.

The codes’ establishment sets a precedent to subsequent laws and lawgivers; in turn, we can look back on the legacy of Ur-Nammu and Hammurabi as the first pages of a memoir — one that tells the story of mankind’s search for justice and fairness in a harsh and often cruel world.

This article was adapted from the original post on Biblion’s secondary website. You’re welcome to visit our main website at



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Daniel Gomes

Daniel Gomes

Content Marketer writing on History, Soccer, Video Games and other random topics — Just having fun and improving my writing skills :)