Erdmates Logo
Erdmates
Back to Blog
NormalizationDatabaseDesignNF

The Complete Guide to Database Normalization: 1NF to 3NF

Understand database normalization step by step, from 1NF through 3NF, with practical examples.

January 17, 20269 min read

What is Database Normalization?

Database normalization is the process of systematically organizing a database's structure to minimize data redundancy and improve data integrity. Proposed by Edgar F. Codd in the 1970s, this theory remains the foundation of relational database design.

Without normalization, databases suffer from three types of anomalies:

  • Insertion Anomaly: Unintended data gets inserted along with desired data
  • Deletion Anomaly: Deleting data unintentionally removes other important data
  • Update Anomaly: Updating data in one place causes inconsistencies elsewhere

First Normal Form (1NF): Ensuring Atomicity

1NF Rule: All column values must be atomic (indivisible). A single column cannot hold multiple values.

1NF Violation Example:

OrderIDCustomerNameProducts
1John SmithLaptop, Mouse
2Jane DoeKeyboard

The 'Products' column holds multiple values separated by commas — this violates 1NF.

After Applying 1NF:

OrderIDCustomerNameProduct
1John SmithLaptop
1John SmithMouse
2Jane DoeKeyboard

Each row now holds one atomic piece of data.

Second Normal Form (2NF): Eliminating Partial Dependencies

2NF Rule: Must be in 1NF, and every non-key attribute must be fully functionally dependent on the entire primary key.

This applies when a composite key (primary key made of multiple columns) exists.

2NF Violation Example:

OrderIDProductIDCustomerNameProductNameQuantity
1AJohn SmithLaptop1
1BJohn SmithMouse2

The primary key is (OrderID, ProductID). However, CustomerName depends only on OrderID, and ProductName depends only on ProductID. These are partial dependencies.

After Applying 2NF:

Orders table:

OrderIDCustomerName
1John Smith

Products table:

ProductIDProductName
ALaptop
BMouse

OrderItems table:

OrderIDProductIDQuantity
1A1
1B2

Third Normal Form (3NF): Eliminating Transitive Dependencies

3NF Rule: Must be in 2NF, and no non-key attribute should transitively depend on the primary key.

In other words, there should be no A → B → C dependency chains.

3NF Violation Example:

StudentIDStudentNameDeptCodeDeptName
1Alice BrownCSComputer Science
2Bob GreenEEElectrical Engineering

DeptName depends on DeptCode, and DeptCode depends on StudentID. Therefore, DeptName transitively depends on StudentID. If a department name changes, multiple rows need updating.

After Applying 3NF:

Students table:

StudentIDStudentNameDeptCode
1Alice BrownCS
2Bob GreenEE

Departments table:

DeptCodeDeptName
CSComputer Science
EEElectrical Engineering

Pros and Cons of Normalization

Benefits

  • Minimized Redundancy: Saves storage space by not repeating information
  • Improved Data Integrity: Only one place to update when data changes
  • Anomaly Elimination: Resolves insertion, deletion, and update anomalies

Drawbacks

  • More JOIN Operations: Split tables require joins for data retrieval
  • Increased Query Complexity: Simple queries may become more complex
  • Potential Performance Impact: Excessive joins can slow down queries

Denormalization

Normalization isn't always the final answer. In performance-critical systems, denormalization — deliberately relaxing normalization — is sometimes applied. For example, storing frequently accessed combined data in a single table to reduce join operations.

In practice, find the right balance between normalization and performance. Normalize to 3NF first, then selectively denormalize only where performance issues are confirmed.

Practical Tips

When designing a database, aim for 3NF normalization. Erdmates' AI optimization feature can automatically detect normalization violations in your current ERD and suggest improvements.

Normalization is better understood through practice with real examples than through memorizing theory.

Start with Erdmates Today

Start designing databases with our AI-powered ERD editor. Free to use.

Try Free DemoStart for Free

Related Articles

bigint, UUID v4, or UUID v7? How to Choose a Primary Key (with PostgreSQL 18's uuidv7())

Compare bigint, UUID v4, and UUID v7 primary keys, see what PostgreSQL 18's built-in uuidv7() changes, and learn which key to pick for each situation.

Databases Read by AI Agents: Schema Design Principles for the MCP Era

AI agents are increasingly connecting directly to databases through MCP. This post covers how to design names, comments, and constraints so agents don't misinterpret your schema, and how to split permissions safely.

PostgreSQL 19 Preview: Changes That Affect Schema Design and Operations (as of Beta 4)

Ahead of its official release, this post covers the PostgreSQL 19 changes that directly affect table design, migrations, and operations, based on the official release notes (Beta 4). It also looks at features reverted during beta and behavior changes to check before upgrading.

Erdmates Logo
Erdmates

Design databases with natural language and collaborate in real-time with your team using our AI-powered ERD editor.

Service

  • Features
  • Pricing
  • Demo
  • SQL to ERD converter

Resources

  • Blog
  • Help
  • Contact Us

Legal

  • Terms of Service
  • Privacy Policy
  • Third-Party Provision
Company: Produx|Representative: 최정회
Address: 강원특별자치도 원주시 솔우물2길 4-1 (무실동)
Email: master@erdmates.com
Privacy Officer: 최정회|Hosting Provider: Amazon Web Services

© 2026 Produx. All rights reserved.