A new column in a database is more than a simple ALTER TABLE. Done wrong, it locks tables, blocks writes, and takes systems offline. Done right, it happens in production with zero interruptions. You need precision at every step.
First, define the purpose of the new column. Will it be NULL by default? Does it require an index? Avoid adding indexes in the same migration. Create them separately to prevent write locks. Small operations finish faster and reduce risk.
Second, choose the correct migration strategy. For large datasets, use online schema change tools like pt-online-schema-change or gh-ost. These stream changes in the background, copying data to a shadow table and swapping it in once ready. Test them in staging with production-sized data before touching live systems.
Third, understand the implications of your database engine. In MySQL, certain column types trigger full table rewrites. In PostgreSQL, adding a column with a constant default value rewrites the table before version 11, but not after. Know your version. Know its limits.