MageSentinel

Five ways a Magento deploy breaks checkout

Magento 2 checkout is a large client-side application sitting on top of a large server-side one. A release can pass every check on staging and still break it in production. These are the patterns that come up again and again.

All posts2 min read

A rocket lifting off in a cloud of smoke
1Static contentmissing JS → endless spinner2Cachesold page, new files33rd-party modulesmixin breaks payment step4Configno shipping for a country5CSPpayment widget blocked
Five layers a deploy touches — each can break checkout while every page still returns 200.

1. Static content that did not deploy

Checkout is built from RequireJS modules and Knockout templates served as static files. If setup:static-content:deploy ran for the wrong locale, the wrong theme, or did not run at all, checkout loads a page shell and then stops: a spinner that never ends, or an empty payment step. The HTML is fine; one missing JavaScript file is not.

Catch it by loading checkout in a real browser after every deploy — not by curling the page.

2. Stale caches and version mismatches

Full-page cache, Varnish, a CDN and the browser all hold copies of something. After a deploy, a cached page can reference a static version that no longer exists, or a new page can meet an old cached section. The symptom is often intermittent: it works for you after a hard refresh and fails for customers.

Flush in the right order, and check from a clean browser with no cookies — which is exactly what a synthetic run is.

3. A third-party module update

Payment, shipping, one-step checkout and tax modules plug deep into the checkout layout and JavaScript mixins. A composer update pulls a new minor version, a mixin now targets a method that changed, and the payment step throws. These rarely show in the server log because the error is in the browser.

When checkout fails right after a deploy, the module list diff is the first place to look.

4. Configuration drift between environments

Shipping methods, payment credentials, allowed countries and minimum order amounts live in the database, not in code. Staging has sandbox keys and a permissive setup; production has something else. A deploy that imports config — or a manual change made the same afternoon — can leave production with no active shipping method for a country, or a payment method switched off.

Monitor a real address in each market you sell to. A run that sees "no shipping methods" is a SHIPPING failure, not a slow page.

5. Content Security Policy

Since Magento 2.4.7, CSP is enforced on checkout pages. A new tracking script, a payment provider domain or an inline script not in the whitelist gets blocked by the browser. The page looks normal until the exact moment the payment widget should appear.

Watch the browser console on checkout after every release, or let a monitor capture it for you as evidence on the run. Related: upgrading Magento 2.4 safely and full page cache and checkout.

Check your own store now with the free Magento checkout test: it walks the checkout in a real browser, Luma or Hyvä, and shows the step where it stops.

If the checkout freezes at the billing or payment step, see Magento checkout stuck on billing.

Common questions

Why does Magento checkout break after deployment?

Most often static content was not deployed for the live theme or locale, caches still hold old versions, a module update changed checkout JavaScript, configuration differs between environments, or a Content Security Policy blocks a payment script.

What should I run after a Magento deploy?

setup:upgrade, setup:di:compile and setup:static-content:deploy for every theme and locale in use, then flush caches, and walk a full checkout on production.

How do I find what broke after a deploy?

Open the checkout with the browser console open: a failed RequireJS file, a 404 on a static file or a CSP violation names the cause.