Referential integrity ensures that relationships between tables remain consistent. It guarantees that a foreign key value either matches a valid primary key in the related table or is NULL, preventing orphaned records and maintaining valid data relationships across tables.