Adding a new column to a database table sounds simple. In production, it is not. Schema changes can lock tables, stall queries, and trigger downtime if executed carelessly. The method you choose depends on the database engine, the size of your data, and how much traffic you can risk.
In PostgreSQL, ALTER TABLE ... ADD COLUMN is the default, but on large tables it may rewrite data. In MySQL, adding a column can be instant with ALGORITHM=INPLACE—or painfully slow if the storage engine falls back to a copy. Many engineers use background migrations to add a nullable column first, backfill it in batches, and then enforce constraints only when ready.
Keep the column definition lean at creation time. Adding indexes or defaults that require a full table rewrite is an avoidable bottleneck. For volatile systems, run the change during low-traffic windows or apply a blue-green deployment strategy. Always test with a staging cluster seeded with production-scale data to measure execution time and lock behavior before touching live systems.