Unjust enrichment occurs when one party benefits at the expense of another in a manner deemed unfair by law, without a legal justification for retaining that benefit. It typically requires restitution to restore the aggrieved party to their original position, preventing the unjust party from profiting from their gain.