Law is a system of rules that regulates and ensures that individuals or groups adhere to societal norms. These rules may be imposed by government through legislation or executive decrees, or established by judges through precedent (in common law jurisdictions). Private individuals can also create legally binding contracts and arbitration agreements. Laws are created and enforced for many reasons, including establishing standards, maintaining order, resolving disputes and protecting liberties and rights. In addition, they serve a social function in dictating behavior and creating incentives for cooperation. Laws may be influenced by the social context and culture in which they are created, and they reflect historical and philosophical trends in human thought.
Laws can be created by either governmental or private institutions, and they are designed to meet the specific needs of particular communities and cultures. These laws can be based on custom, tradition or religion; or they can be the product of an evolutionary process. In many cases, the laws of one community differ from those of another; this is often due to a lack of common cultural or linguistic features between the two. Consequently, the legal systems of countries around the world are quite diverse.
Some governments are more authoritarian than others; they are more likely to impose social stability through military and political power. In contrast, democratic states are able to build societies that offer opportunity and equity for all their citizens, regardless of wealth or ethnicity. The degree to which a government or society abides by the rule of law is a key measure of its success.
Throughout history, law has been shaped by changing economic and social conditions. In some cases, it has been consolidated by central authority, as in the case of Roman law, which was codified and became the basis of most modern legal systems. In other cases, it has been adapted by individual judges, as in the case of English common law, which was developed from precedent. In some cases, it has been based on religious doctrines, as in the case of Islamic Sharia law.
The law influences politics, economics, history and society in many ways; it is therefore a subject of intense scholarly inquiry. In particular, the legal science of law encompasses a wide range of disciplines, such as legal philosophy and history, sociology and anthropology, economic analysis and politics. Laws can be categorized into civil and criminal, as well as into fields such as family, labor, maritime, aviation and medical jurisprudence. Laws can also be applied on a global scale, as in the case of international law or the law of war. For more on these topics, see law, philosophy of; legal history; law, economics of; and law, sociology of.