In law, a legal opinion is usually a written explanation by a judge or group of judges that accompanies an order or ruling in a case, laying out the rationale and legal principles for the ruling.
Opinions are usually published at the direction of the court, and to the extent they contain pronouncements about what the law is and how it should be interpreted, they reinforce, change, establish, or overturn legal precedent. If a court decides that an opinion should be published, the opinion is included in a volume from a series of books called law reports (or reporters in the United States). Published opinions of courts are also collectively referred to as case law, which is one of the major sources of law in common law legal systems.
Not every case decided by a higher court results in the publication of an opinion; in fact many cases do not, since an opinion is often published only when the law is being interpreted in a novel way, or the case is a high-profile matter of general public interest and the court wishes to make the details of its ruling public. In the majority of American cases, the judges issue what is called a memorandum decision that indicates how state or federal law applies to the case and affirms or reverses the decision of the lower court. A memorandum decision does not establish legal precedent or re-interpret the law, and cannot be invoked in subsequent cases to justify a ruling. Opinions, on the other hand, always establish a particular legal interpretation.