Law is a system of rules created and enforced by social or governmental institutions to regulate behavior. Its precise definition is a matter of longstanding debate. It shapes politics, economics, history and society in many ways. Law is a source of scholarly inquiry into legal philosophy, history, sociology and economic analysis and it raises fundamental issues about equality and justice. The law serves many purposes but four are primarily important: establishing standards, maintaining order, resolving disputes and protecting liberties and rights.
A general distinction can be made between civil law jurisdictions where legislation (or a constitution) sets out the rules, and common law systems where judges make laws through precedent. However, it is more common to find a combination of the two. Religion has a significant influence in some countries where Sharia law, for example, is the primary source of law.
The law can be divided into several categories, such as criminal law dealing with the punishment of individuals for violations of social norms and a civil code governing contracts, property, family and other relationships. There are also specialized areas such as aviation, maritime and commercial law, bankruptcy law, medical jurisprudence and evidence law.
It is possible to argue that there are different types of laws, but this is not straightforward. Blackstone and other early legal thinkers distinguished between natural law, revelation or divine law, common law, municipal law and religious law. The latter were based on concepts of morality, natural justice or the will of God.
The process by which the law is adopted, administered, adjudicated and enforced must be clear, publicized and stable and must ensure that human rights as well as property and contract rights are protected. It must be accessible and fair, and be interpreted by people who are competent and ethical and reflect the makeup of the communities they serve.
It is essential for the legal system to be impartial and not tainted by corruption or nepotism. This requires that the people who administer the law are trained and qualified, and have adequate resources to ensure a high level of service. It is also necessary that the people who are involved in the lawmaking process are representative of the communities they serve and are accountable to those communities for their actions. The law must be transparent and fair, and the laws enforced by competent and impartial judges and magistrates who are accessible and represent all communities fairly. These principles form a framework for the rule of law. They have been internationally tested and developed with a variety of experts worldwide. See the articles on the rule of law for more detail.