Adding a new column in production is more than running ALTER TABLE table_name ADD COLUMN column_name data_type;. The command is trivial. The impact is not. Schema changes lock tables, consume I/O, and can block writes. On high-traffic systems, the wrong approach can freeze an application.
Performance depends on your database engine. PostgreSQL handles ADD COLUMN with a default value efficiently when it’s NULL. But setting a non-null default rewrites the table on disk. MySQL may also block reads or writes depending on its version and engine. Always test in a staging environment with realistic data size before deploying.
Versioning is essential. Align the new column with your application release so unused columns do not linger. Deploy the schema change first, then roll out code that writes to the new column. For backwards compatibility, keep reading from the old path until the migration completes and indexes are built.