Last Updated on by Dan S
Originally Published April 3, 2021.


While editing your Shopify theme, if you accidentally delete a liquid template, there’s no need to worry as it can be recovered in most cases. But how do you do this?

First off, you should ALWAYS back up your Shopify theme before making edits. Sometimes tech fails and having a backup is a surefire way to get you back on track if that happens.

Shopify Theme Revisions

If you edit a template file in the Shopify Theme Code Editor, Shopify logs these changes. You can now rollback to a previous state of the edited theme file in just 2 clicks.

recover liquid theme shopify template

This is great if you have recently edited the file or want to rollback to its original state. If the file is missing however, you will need to upload a replacement.

Accidentally deleting a Shopify Liquid template: What’s the solution?

If you accidentally delete a Shopify liquid template, you need to redownload the original theme to your Shopify store. If you purchased an Official Shopify Theme from the Theme Store, you can easily redownload another copy of it.

If the version you are trying to replace is newer or your original version was heavily edited, it may encounter some difficulty. In this instance you would need to weigh up the pro’s and con’s of restoring and troubleshooting versus transferring over to the newly updated theme.

If the theme is saved locally to your machine or came from a 3rd party marketplace, you will need to re-upload it.

Here’s what to do:

  • Step 1: Upload the theme but do not Publish it.
  • Step 2: In the unpublished theme, look for the template or file that is missing from your Published theme.
  • Step 3: Download or Copy its contents
  • Step 4: Make a blank version of that missing file in the published theme if you have copied the contents. If you downloaded, skip to Step 5.
  • Step 5: Paste the file’s content into the Blank version of the template and Save or upload the missing template/file you downloaded

Some helpful apps

Apart from this method, the best way to prevent mishaps in your Shopify store is to create a backup before you edit the theme.

Here are some apps to help you track changes, backup data and recover various aspects of your Shopify store.

Undo

Undo App Shopify Liquid Template

The Undo app lets you undo changes that you’ve accidentally made to your Shopify store. You can securely back up products, collections, blogs, and more with daily automated backups and incident-based change tracking.

The recovery is easy as you only have to press a button to restore any unwanted or accidental store changes.

ThemeWatch

ThemeWatch Shopify Liquid Template

The ThemeWatch app automatically backs up your themes and lets you recover them. If developers or third-party apps are making any changes to your store, the app lets you keep an eye on them.

Additionally, you can keep the theme’s information safe owing to the daily backups made by the app. You can also manually back up your theme before making any updates.

Furthermore, you can restore the theme to a previous state by backing up the whole theme or any specific asset.

Hopefully, this information will help you get your native theme with its liquid template back.