Start Free TrialFree Trial

Changing A URL On Shopify Without Losing The Old One

When you change a product or collection address on Shopify, a redirect sends shoppers and search engines from the old address to the new one. Shopify offers one for some changes, and you can make the rest by hand.

In Shopify How-Tos ยท Last Checked

Before You Start

  • You can edit products, collections and menus in your Shopify admin.
  • You have a good reason to change the address. Shopify's help warns that editing a handle too often can keep a page out of search results.
  • You have written down the old address exactly, before you change anything.

On Shopify, the last part of a product or collection address is called its handle. In /collections/indoor-pots, the handle is indoor-pots. You can change it. When you do, the old address stops working unless a redirect sends visitors on to the new one. Without a redirect, every old link, bookmark and search result leads to a page that is not found.

When It Is Worth Changing An Address

Most of the time, leave addresses alone. Google says it generally does not use the structure of an address to work out the structure of a site, and a change always carries some risk. A change can be worth it when:

  • the address says nothing about the page, such as /collections/copy-of-summer-2 or /products/sku-48213
  • the collection now sells something different from what its address says
  • two collections are being merged into one

It is rarely worth it just to add a search term to an address that already describes the page.

What A Redirect Does

A redirect tells a browser or a crawler that a page has moved and where to. Google's guidance says a permanent redirect is the right kind when a move will not be reversed, and that it then treats the new address as the one to show in search results. It recommends a permanent, server side redirect whenever possible when you change a page's address. Google also lists redirects first among the signals it uses to pick which address represents a page.

Changing A Collection's Handle

Shopify's collection help includes a redirect option when you change a handle.

  1. From your Shopify admin, go to Products, then Collections, and open the collection.
  2. In the Search engine listing section, click the edit icon.
  3. Change the URL handle. It cannot contain spaces. Use lower case words joined by hyphens.
  4. Make sure the option to create a redirect from the old address is selected. In the Shopify app it is labelled Create a URL redirect from the previous handle.
  5. Click Save.

Changing A Product's Handle

  1. From your Shopify admin, go to Products and open the product.
  2. In the Search engine listing section, click the edit icon and change the URL handle.
  3. Look for an option to create a redirect from the old address, and make sure it is selected if you see one.
  4. Click Save.
  5. Test the old address in a browser. If it does not take you to the new page, create the redirect by hand as below.

Shopify's product help, as checked on the date at the top, does not describe a redirect option for product handles, so step 5 matters.

Creating A Redirect By Hand

Use this when a page has moved without a redirect, when you merge two collections, or when you delete a product and want its address to lead somewhere useful.

  1. From your Shopify admin, go to Content, then Menus.
  2. Click View URL redirects.
  3. Click Create URL redirect.
  4. In Redirect from, enter the old address, such as /collections/indoor-pots.
  5. In Redirect to, enter the new address, such as /collections/indoor-plant-pots. Shopify's help says you can enter / to send it to the home page.
  6. Click Save redirect.

Two rules from Shopify's help to know before you start:

  • A redirect only works from an address that no longer loads a page. If the old address still shows a live product or collection, the redirect is ignored. Change the handle or remove the old page first.
  • There is a limit. Shopify's help gives a maximum of 100,000 URL redirects for a store, and 20,000,000 on Shopify Plus.

Many Redirects At Once

If you are changing many addresses, Shopify's URL redirects page has Import and Export buttons that take a CSV file. Shopify's help offers a sample file to fill in. Export your current redirects first so you have a copy.

Where To Send A Redirect

Send each old address to the page that is closest to what it used to be.

Example. A store that sells ceramic plant pots merges its "Small Pots" and "Mini Pots" collections into one called "Small Plant Pots". Both old addresses redirect to the new collection. A pot that was discontinued redirects to the collection it used to sit in, not to the home page, because that is where a shopper looking for it is most likely to find a replacement.

Our reading is that sending everything to the home page is a poor choice. A shopper who followed a link to a particular pot lands somewhere that has nothing to do with it.

Avoid Chains

If an address has moved twice, the oldest one may redirect to an address that itself redirects. Google's redirect guidance does not set a rule on this, but we think it is better for every old address to point straight at the final one. It is one hop for the shopper, and less for a crawler to follow. When you change an address that already has redirects pointing at it, update those redirects to point at the newest address.

After The Change

  1. Test the old address in a private browser window.
  2. Update the links you control: menus under Content, then Menus, links in collection descriptions, blog posts and pages.
  3. Check the new page's canonical tag in its page source names the new address.
  4. Leave the redirect in place. Old links on other sites and in shoppers' bookmarks keep arriving for a long time.

How You Know It Worked

  • Typing the old address into a browser lands you on the new one.
  • The redirect is listed under URL redirects in your admin, from the old address to the new one.
  • Your menus, collection descriptions and other pages link to the new address, not the old one.

Sources

If a step here no longer matches your admin, tell us at help@collectionoptimizer.com and we will check it again.