Continuous delivery (CD) is a software engineering practice where every code change is built, tested and prepared for release automatically, so the software is always ready to ship. It builds on continuous integration (CI). The main thing that separates it from continuous deployment is the last step: in continuous delivery, a person still decides when a tested build goes live to users.
The term caught on through the 2010 book Continuous Delivery by Jez Humble and David Farley, both formerly of Thoughtworks. The phrase itself appears earlier, in the first principle of the Agile Manifesto (2001): “Our highest priority is to satisfy the customer through early and continuous delivery of valuable software”.
How continuous delivery works
Continuous delivery works through a deployment pipeline, which is an automated sequence of steps that every code change passes through on its way to production. Continuous delivery takes automation from source control all the way through production. A typical pipeline has these stages:
- Commit. A developer pushes a change to the shared code repository, and that push starts the pipeline.
- Build. The pipeline compiles the code and packages it into an artifact, the single deployable file or container image that every later stage uses.
- Automated tests. Unit tests, integration tests, and often security and performance checks run against the artifact. If any test fails, the build stops and the team gets an alert.
- Staging deployment. The passing build goes to a staging or test environment that closely mirrors production, and acceptance tests run there.
- Release decision. The build is now releasable. A developer, team lead or release manager approves it, and the same automated process pushes it to production.
The idea behind all of this is that the software stays “green,” meaning deployable, at all times. Put simply, continuous integration makes sure the software always builds, and continuous delivery makes sure it always deploys. Because the release process is scripted, the deployment process and scripts are tested repeatedly before deployment to production.
An everyday analogy
Picture a busy restaurant kitchen. Continuous integration is the line cooks checking each ingredient and component as they prepare it. Continuous delivery means every dish is fully cooked, plated and waiting at the pass, ready to go. The server still decides when to carry it to the table. Continuous deployment drops the server: each dish goes out the moment it’s ready.
Continuous integration vs. continuous delivery vs. continuous deployment
These three practices are steps on one path. Each one automates a little more of the trip from a developer’s laptop to the user. Continuous delivery includes continuous integration, and continuous deployment takes continuous delivery one step further. Dave Farley has said that continuous delivery as he and Humble defined it incorporates continuous integration.
| Practice | What gets automated | Where the change ends up | Human approval before production? |
|---|---|---|---|
| Continuous integration (CI) | Merging code into a shared repository, then building and testing it | A tested build in the repository | Not applicable (CI stops before release) |
| Continuous delivery (CD) | Everything in CI, plus packaging, deploying to staging and acceptance testing | A release-ready build, staged and waiting | Yes, a person triggers the release |
| Continuous deployment | Everything in continuous delivery, plus the production release | Live in production for users | No, every passing change ships automatically |
Continuous deployment is the most automated of the three. At that stage, teams are so confident in their automated build and deploy process that any checked-in code that passes its tests can be deployed immediately. One more term to keep separate: deploying means putting code on production servers, while releasing means turning a feature on for users. Teams often deploy code hidden behind a feature flag (a setting that switches a feature on or off) and release it later.
A real-world example of continuous delivery
Here is a continuous delivery pipeline at an online store. A developer fixes a bug that shows the wrong shipping price at checkout. In plain terms, this is what happens next:
- Minutes after the fix is pushed, the pipeline builds the app and runs the test suite, including a test written to catch this exact bug.
- The build passes, so the pipeline deploys it to staging, where automated checkout tests place fake orders.
- Staging passes too, and the release dashboard marks the build as ready.
- The team lead clicks release on a quiet Tuesday morning instead of waiting for a monthly release window. If anything looks wrong, the team rolls back to the previous artifact.
Common tools for building pipelines like this include Jenkins, GitLab CI/CD, GitHub Actions, AWS CodePipeline and JetBrains TeamCity. The practice doesn’t depend on any one product.
Benefits and drawbacks of continuous delivery
The main benefit of continuous delivery is lower release risk. It reduces risk by making releases smaller, more frequent, and more predictable.
- Easier bug fixing. When a release contains only a few changes, it’s much quicker to find which one caused a problem than when hundreds ship together.
- Faster time to market. Long code freezes and manual staging handoffs disappear. According to the book’s publisher, teams can get changes released in a matter of hours—sometimes even minutes.
- Higher quality. Automated regression, security and performance tests run on every change, so problems surface early.
- Room to experiment. Teams can put experimental changes in front of users early and see which ones are worth keeping.
Continuous delivery has real costs too:
- Upfront investment. You have to build and maintain the pipeline, test suites and staging environments.
- Test automation is mandatory. Without automated tests, developers can’t trust the pipeline, and continuous delivery stalls.
- Culture change. Continuous delivery is not just about tools and automation; it is also about culture, and Humble and Farley argue that successful adoption requires collaboration across the entire organization.
Common continuous delivery mistakes
The mistake that undermines continuous delivery is calling a pipeline “continuous delivery” while manual steps or long-lived code branches still slow every release. Watch for these problems:
- Long-lived feature branches. Humble and Farley argue that if different members of the team are working on separate branches or streams then by definition they’re not continuously integrating.
- Rebuilding for each environment. Build the artifact once and promote that same artifact through staging to production. Otherwise you ship something you never tested.
- Manual deployment steps. Continuous delivery depends on automating almost every step. Manual steps make frequent, reliable releases hard to sustain.
- Ignoring red builds. If a broken build sits unfixed, the software is no longer releasable, and that defeats the whole point.
How to tell if your team is really doing continuous delivery
A team is practicing continuous delivery if it could release the current main branch to production today, safely, with one approved action. Two quick checks: Is your main branch deployable right now? Can anyone on the team trigger a release without a runbook full of manual steps? To track progress over time, many teams use the four delivery metrics from the DORA research program co-founded by Jez Humble: deployment frequency, lead time for changes, change failure rate and time to restore service.
FAQ
– What is the difference between CI and CD?
CI (continuous integration) automatically merges and tests code changes in a shared repository. CD (continuous delivery) picks up where CI ends and carries each tested build through staging until it’s ready for production. CI tells you the code works. CD tells you it can ship. In “CI/CD,” the CD can mean either continuous delivery or continuous deployment, depending on whether a person approves the final release.
– Is continuous delivery the same as continuous deployment?
No, continuous delivery and continuous deployment are not the same. Continuous delivery keeps every passing build ready to release but waits for a person to approve the production push. Continuous deployment removes that approval, and every change that passes the pipeline goes live automatically.
– Is Jenkins becoming obsolete?
No, Jenkins is not obsolete. It’s still an actively maintained open-source automation server for building CI/CD pipelines. Many teams now also use CI/CD built into their code hosting platform, such as GitHub Actions or GitLab CI/CD, or cloud services like AWS CodePipeline. The right choice depends on where your code lives and how much server upkeep you want to handle.
– Do you need microservices for continuous delivery?
No, microservices aren’t required for continuous delivery, though they’re a common fit. Microservices are often used when architecting for continuous delivery because small, independent services can be tested and released on their own. A single large application can still use continuous delivery if it has a reliable automated pipeline and good test coverage.