Systems & Backend

API Versioning

Evolving an API without breaking existing clients — via version in the path, header, or backward-compatible changes.

API versioning is how you change an API over time without breaking clients already using it. Common approaches: a version in the URL path (/v1/…), a version header, or simply making only additive, backward-compatible changes and never removing or repurposing existing fields.

Worked example: introducing a breaking change to a response shape, you expose it under /v2 while /v1 keeps working, then deprecate /v1 with a timeline once clients migrate. Gotcha: every version you support is code you must maintain and test forever, so prefer additive changes (new optional fields) that need no new version; and a hard breaking change without a deprecation window and clear communication will break integrations you did not know existed.