Skip to content
Tutorials Center
My learning

Topics

Lesson 50 of 61 ยท Publishing and Maintenance

Testing, Publishing and Going Live

Preview, test and publish a Shopify theme safely: preview links, a QA checklist, rollback by republishing, password page, domain setup and a launch checklist.

Publishing a Shopify theme is one button. That is the dangerous part. The button is easy to press and the result is instantly visible to every shopper, so the work that matters happens before it: previews, a checklist, a backup you can return to, and a plan for the first hour after launch.

This lesson covers that whole path for a theme update on an existing store and for the first launch of a brand-new store. It assumes you already keep your code in Git as described in Version Control and Team Workflows.

The admin screens and CLI commands below are read-only descriptions of real Shopify features, because this site cannot reach a store. The live example is a JavaScript stand-in that runs a checklist and models a theme library, so you can see the rules at work. Menu names and limits change over time; confirm them in your own admin.

The life of a theme in the library

Every theme in a store has a role. Understanding the roles explains most of the process.

  • Published (main): the theme shoppers see. There is exactly one.
  • Unpublished: a theme sitting in the library. Shoppers cannot see it, but you can preview it.
  • Development: a temporary theme created by shopify theme dev for one developer. It is hidden from the normal list of customer-facing themes and is not meant to be published.

Publishing swaps roles: the chosen theme becomes published, and the old published theme becomes unpublished. Nothing is deleted, which is what makes rollback possible.

flowchart LR
  A["Local code<br/>and Git"] --> B["Development theme<br/>shopify theme dev"]
  B --> C["Unpublished theme<br/>push and preview"]
  C --> D{"QA passed?"}
  D -- no --> B
  D -- yes --> E["Publish<br/>roles swap"]
  E --> F["Previous theme<br/>kept as backup"]

Code moves from a development theme to an unpublished one, and only then to the live role.

Preview before anything else

You can look at a theme without publishing it in three ways.

  1. From the admin. The theme library has a Preview action on every theme. It loads the store with that theme applied. While previewing, a bar at the bottom lets you leave the preview or open the editor.
  2. A shareable preview link. In the theme actions you can copy a preview link, and the CLI can create one with shopify theme share, which uploads your local files as a new unpublished theme and prints a URL. Anyone with the link can view the theme, so it is perfect for a client or a teammate. Treat the link as unlisted, not secret.
  3. The local server. shopify theme dev serves your files on your own machine with live reload, as covered in Setting Up: Dev Store, Partner Account and Shopify CLI. It is the fastest loop but it is not the same as a real preview, because it runs against a temporary theme and only your computer sees it.

Preview with real data. An empty development store hides problems that a catalog with 3,000 products, long product names and missing images will expose.

A QA checklist that earns its keep

Test the flows that make money first, then the details. The list below fits most stores; add your own rows for custom features.

Shopping flow

  • Home page, a collection, a product page, search, cart and checkout all load.
  • A product with several variants updates price, image and availability when options change (see Variants and Option Pickers).
  • Add to cart works from the product page, a quick add button and the cart drawer.
  • A sold-out product and a product without images do not break the layout.
  • Discount code entry and shipping estimates behave as expected. For the checkout steps and tax or shipping behavior that Shopify controls, see Checkout Flow, Taxes and Shipping Rates.

Account and content

  • Login, registration, password reset and the order history page.
  • The contact form sends a message, and the newsletter form shows a success state.
  • Blog index, an article, and a custom page.
  • The 404 page and the search page with no results.

Devices and browsers

  • A small phone width, a tablet, a laptop and a very wide monitor.
  • Current Safari, Chrome and Firefox. Safari is where many layout and input bugs appear first.
  • Keyboard only: can you reach the menu, the cart and the checkout button? See Accessibility in Themes.

Quality

Settings and content

  • Open the theme editor and add, remove and reorder sections on every template. A theme that works only with its demo layout is not finished.
  • Check that translations exist for each language the store sells in (Translations, Markets and Localization).

Publishing

Once the checklist passes, publishing is a two-step action in the admin: open the theme's actions menu and choose Publish, then confirm. The CLI offers shopify theme publish for automated pipelines. Both do the same thing: swap roles.

Choose the time well. For a store with steady traffic, publish during the lowest-traffic window, not at the start of a sale. Do not publish on Friday afternoon if nobody is watching on Saturday.

Before you publish, duplicate the current live theme from its actions menu and rename the copy with the date (for example Live backup 2026-10-30). Publishing keeps the old theme around anyway, but a named copy survives later cleanups, and it protects you if someone edits the old theme afterward.

Theme limits

A store can only hold a limited number of themes. If you try to add one over the limit, Shopify asks you to delete an old theme first. Keep the library tidy: delete abandoned experiments, keep one backup of the live theme, and keep one staging theme. The exact limit has differed between plans and over time, so look it up in your admin rather than relying on a number from a lesson.

Rollback

If something goes wrong after publishing, the fastest fix is not a hotfix. It is publishing the previous theme again, which restores the old storefront in seconds. Then you debug the new theme calmly on an unpublished copy.

There is one catch: edits the merchant made after the swap live in the new theme only. A rollback returns them to the older state. Tell the team to pause content edits during the first hours, and keep the backup copy until the new theme has proven itself.

Rollback can also be checked in small steps with the stand-in below.

Stand-in: a launch checker and a theme library

The first example models a store's state as an object and runs a list of rules against it, printing a pass or fail for each. The rules reflect this lesson's checklist. The store object is a stand-in; real values come from your own inspection of the admin and the site.

JS Stand-in: a launch checklist runner

Press Run (or Ctrl + Enter) to see the console output here.

No output.

The second example models the theme library, with roles, publish and rollback. It shows why publishing never deletes anything and why a rollback is one more publish.

JS Stand-in: publish and roll back

Press Run (or Ctrl + Enter) to see the console output here.

No output.

The password page

A new store starts password protected, so shoppers see a holding page and not your products. The setting is in the online store preferences, and the page itself is your theme's layout/password.liquid and templates/password.json, plus a section that usually shows a message, a newsletter sign-up and the password form. Style it, because it is often the first page people see.

Keep the password on until the QA list is done and the domain works. Turn it off as one of the last steps of a first launch. Watch out for stores where the password page is on by accident after a migration: search engines see nothing and sales stop.

Connecting a domain

Every store has a something.myshopify.com address. For a branded address you buy a domain through Shopify or connect one you own. In the domain settings of the admin you choose to connect an existing domain and update the DNS records at your registrar. For a root domain that normally means an A record pointing to Shopify's address, and for www a CNAME record pointing to shops.myshopify.com. The admin shows the exact values and checks the connection, so use those and not a number copied from an article.

Then:

  • Set the primary domain and let Shopify redirect other domains to it, so there is one canonical address for search engines.
  • Wait for the SSL certificate to be issued; HTTPS can take a while after DNS changes.
  • Expect DNS changes to take time to spread. Plan the switch ahead and do not rely on it being instant.
  • If you are replacing an old site, set up URL redirects for the pages that had traffic before you switch.

A launch checklist

Use this as a final gate for a first launch. Each item is something that went wrong for somebody.

  1. Backup of the previous site or theme exists.
  2. The QA list above is complete on real devices.
  3. Legal pages (privacy, terms, refund policy, shipping policy) are filled in and linked in the footer.
  4. A real order was placed in a test, and the confirmation email arrived. For the order flow, see Webhooks and Orders for Theme Developers.
  5. Analytics and ad pixels fire exactly once, and a cookie banner works if you need one (Theme App Extensions and Third-Party Scripts, Analytics and Tracking).
  6. Favicon, social sharing image and the store name are set.
  7. The domain is connected and the primary domain is chosen.
  8. The password page is turned off.
  9. The sitemap is reachable and you have submitted it to search engines.
  10. Someone is watching the store, the console and the first orders after publishing.

Check your understanding

Quick check ยท 5 questions

of 5 answered You scored / 5 ยท perfect!

  1. 1. What happens to the old live theme when you publish a new one?

    Publishing swaps roles. The previous theme remains as an unpublished theme, which is what makes a quick rollback possible.
  2. 2. What is the fastest way to recover from a bad publish?

    Republishing the old theme restores the storefront at once. You can then fix the problem on an unpublished copy.
  3. 3. Why should you test with a store that has realistic data?

    Layouts often break on long titles, products with many options, or items without images, which a nearly empty dev store never shows.
  4. 4. What is a shareable preview link good for?

    A preview link shows an unpublished theme to anyone who has the link. It is unlisted, not private, so do not put secrets in it.
  5. 5. Which is the right order for a first launch?

    Keep the store hidden while you test. Open it at the end, once QA passes and the domain works.

Summary

  • A theme's role (published, unpublished, development) explains the process: publishing swaps roles and deletes nothing.
  • Preview in the admin, with a shareable link, or locally with shopify theme dev, and use realistic data.
  • Test the money flows first, then accounts and content, devices and browsers, and quality tools.
  • Keep a dated backup copy of the live theme and know the rollback: publish the previous theme again.
  • For a first launch: legal pages, test order, analytics, domain, password page off, and someone watching afterward.

Next, if you plan to sell a theme to many merchants, read Theme Store Requirements and Selling a Theme.