Adding a new column should be simple. In practice, it can break production if done wrong. Large datasets, high traffic, and strict uptime requirements mean every schema change is a risk. The safest path depends on your database, your workload, and your deployment strategy.
In PostgreSQL, adding a nullable column with no default is instant. Adding a column with a default value rewrites the table—this can lock writes and block queries. In MySQL, both storage engine and version matter. In older MySQL versions, any column addition is a blocking operation. Newer versions with ALGORITHM=INPLACE reduce locking, but constraints still apply when defaults or indexes are involved.
For zero-downtime migrations, you can break the change into steps. First, add the new column as nullable with no default. Second, backfill data in batches to avoid locking. Third, add defaults and constraints once the data is ready. This reduces the chance of long-running locks and slow queries.