How to Edit a Shopify Theme Without Breaking Your Store
Duplicate the theme first so you have a backup, then open the copy in the theme editor and change sections, blocks and theme settings with no code. Preview it, and publish only when it looks right. Use Edit code only for changes the editor cannot make, and copy any file before you change it.
| Method | What you change | Needs code? |
|---|---|---|
| Theme settings | Colours, fonts, buttons and other store-wide styles | No |
| Sections and blocks | What appears on each page and in what order | No |
| Edit code | Liquid, CSS and JavaScript files of the theme | Yes |
| Local development | The whole theme, with version control | Yes |
Updated
Shopify's theme editor lets you rearrange your store without touching code, and most owners never need more. Work through the checklist below in order. It keeps a safe copy at every step, so a bad change costs you a minute rather than a lost weekend.
Safe editing checklist
- Duplicate the live theme from Online Store
- Rename the copy so you can tell it apart
- Open the copy with Customize
- Set colours, fonts and buttons in theme settings
- Add, hide or reorder sections and blocks
- Preview on a phone and on a computer
- Publish the copy
What the editor saves for you
Each page type in a modern theme is a JSON template: a list of sections, their settings and their order. The theme editor writes this file when you drag things around, which is why you rarely need to edit it by hand.
A small product page template
The sections object holds each section and its settings; order is the list Shopify renders from top to bottom.
{
"sections": {
"main": { "type": "main-product", "settings": {} },
"reviews": { "type": "rich-text", "settings": {} }
},
"order": ["main", "reviews"]
}
When to open Edit code
Shopify advises editing theme code only if you know HTML and CSS and have a basic grasp of Liquid, its template language. Typical reasons are a small style tweak the settings lack, or a snippet an app asks you to paste.
Before saving, copy the original file into a text file on your computer. That gives you a second safety net next to Shopify's own timeline.
Why the duplicate matters
A copy appears in your theme library as Copy of plus the original name. Rename it to something clear, like the date and what you changed, so you can tell versions apart later.
Publishing a copy is reversible: the previous theme is still in the library, and you can publish it again if sales drop or something looks broken.
How it works
- From your admin, go to Online Store, open the actions menu on your theme and click Duplicate.
- Click Customize on the copy, not on the live theme, to open the theme editor.
- Add, hide, reorder or delete sections and blocks, and set store-wide styles in theme settings.
- Preview the copy, then publish it when you are happy. The old theme stays in your library as a fallback.
Tips
- Hide a section instead of deleting it when you are unsure. A hidden section keeps its content for later.
- Each template can hold up to 25 sections, and up to 1250 blocks across all of them, so very long pages need trimming.
- If a theme update conflicts with code you changed, Shopify warns that your code changes are removed in the updated copy. Keep notes of every edit.
- You can see your theme's developer and version number in the theme editor, which helps when you contact support.
Frequently asked questions
Will editing my theme change the live store right away?
Edits to the published theme go live when you save. Editing an unpublished duplicate changes nothing for customers until you publish that copy.
What is the difference between a section and a block?
A section is a full-width part of a page, such as a slideshow or featured collection. Blocks are the smaller pieces inside it, like a heading, a button or an image.
How do I undo a code change?
In the code editor, a file's Timeline view can restore an older version. Shopify notes that timeline history is finite and that restoring replaces the whole file, so copy anything you want to keep first.
Can Shopify Support edit my theme for me?
For Shopify-made themes, support may help with certain predefined customizations but does not write custom code. For a paid theme, ask its developer, or hire a Shopify Partner for custom work.
How many copies of a theme can I keep?
Stores on Basic, Grow and Advanced plans can hold up to 20 themes. If you reach the limit, you must delete one before duplicating another.
Related: Shopify theme development, How to start a Shopify store, Free Shopify themes, Shopify pricing.
Build your site free or see all free tools. On We.Inc you can build your site free, with no card and no trial needed to start. AI building is on paid plans from $19 a month.
More in Guides
- How to Embed a Tweet (X Post) on Your Website
- How to Embed a Facebook Page on Your Website
- How to Embed Google Calendar on Your Website
- How to Embed a Google Form on Your Website
- How to Embed an Instagram Feed on Your Website
- How to Embed a PDF on Your Website
- How to Embed Spotify on Your Website
- How to Embed a TikTok Video on Your Website
Product
Who It's For
- For Agencies
- For Freelancers
- For Hosting Providers
- For SaaS Platforms
- For Startups
- For Financial Services
- For Healthcare
Features
Resources
- Blog
- Help Center
- Free Business Tools
- Free UI Components
- Website Templates
- Template Collections
- Website Examples
- Guides
- Comparisons
- Alternatives
- Best Lists
- Reviews
- Pricing Guides
- Use Cases
- Glossary & Guides
- Integrations
- Developers
- Benchmark
- Windows App