Consumer law is a branch of law that regulates the rights of consumers in transactions and ensures fair trade, competition, and accurate information in the marketplace. It provides protection against fraud, unfair practices, and unsafe products, thereby promoting consumer confidence and welfare.