Adding a new column is simple in theory. Done right, it keeps systems predictable and fast. Done wrong, it causes downtime, corrupt data, and broken features. The difference is in the details.
Start by defining the column at the database layer with the correct data type. Choose NULL-ability and default values carefully—these decisions affect every query and index. If the table is large, avoid locking reads and writes for too long. Many relational databases allow adding a column without a full table rewrite; use that path when available.
Migrations should be explicit and reversible. Write code that makes the schema change separately from the code that depends on it. Deploy the column first, then update the application logic to read and write to it. In distributed systems, this two-step rollout prevents race conditions and ensures forward and backward compatibility during deploys.