Adding a new column to a production database is simple in concept and dangerous in practice. The wrong step can lock tables, slow queries, or crash services. The right approach keeps your system online and your data consistent.
The first step: understand the impact. Check indexes, query plans, and downstream dependencies. Know where this new column will be read, written, and updated. Audit ORM models and migrations. Look at your test coverage. A small blind spot can cause long outages.
Next, choose your migration strategy. For SQL databases, use ALTER TABLE carefully. On large datasets, consider adding the column as nullable, backfilling data in batches, then enforcing constraints later. For schema-less stores, design the new field to be forward-compatible, with defaults handled cleanly in application code.