A declaratory judgment is a court's formal statement regarding the legal relationships and rights of parties in a dispute, without ordering any specific action or awarding damages. It serves to clarify legal uncertainties, allowing parties to understand their rights and obligations before further legal proceedings or actions are taken.