← Back to Glossary

Natural key

A natural key is an identifier that comes from real-world business data — like an email address, SSN, or product SKU — as opposed to a surrogate key generated purely for database use.

Overview

A natural key (also called a business key) is a column, or set of columns, that uniquely identifies an entity using data that already has meaning outside the database: an email address, a national ID number, a vehicle VIN, a source system's customer_id. It's the identifier a business person would recognize and use.

Natural keys are useful and often necessary — they're how you match and deduplicate records coming from a source system, and how you'd look a record up manually. But dimensional models generally avoid using them as the primary key of a dimension table, in favor of surrogate keys, for a few practical reasons: natural keys can change (an employee ID gets reissued, an email address changes), can collide across source systems using different formats or numbering schemes, and can't represent more than one historical version of the same entity, which slowly changing dimensions require.

Related terms

FAQS

It can, and is common in simple operational schemas. Dimensional warehouses typically avoid it for dimension tables, though, because natural keys can change and can't represent multiple historical versions of an entity, which surrogate keys handle cleanly.