Route Mapping

This article is intended for advanced users and our partners as it requires advanced web development or Salesforce admin or programming knowledge. While the functionality is part of StoreConnect, we do not provide end user assistance to implement it beyond our help documentation. If you need help or are unsure on how to do this, you can hire one of our StoreConnect partners.

Route mappings allow you to create permanent (301) and temporary (302) redirects as well as a special ‘rewrite’ which renders the existing content without any redirect. Any of these will take a visitor who lands on an old URL to the new URL so they arrive where they intended.

A permanent route mapping (301) is automatically created when a slug or path is changed for any of these records:
Product Category
Article Category

Video on how permanent route mapping (301) works, see how route mapping is created after changing a slug on a product and how it redirects a visitor from the old URL to the new URL:

A route mapping record can be deleted if the redirect is no longer required. Your route mapping records can be found in the StoreConnect Config app.

A slug must be unique for each product. A path must be unique for each store, meaning a page can share a path with another page as long as they each belong to different stores.

It can occur sometimes where you try to create a new record and you get an error saying the slug or path must be unique. After checking, you find there is no other record with the same path. What likely happened is that a record did once have that same path, was given a new path (route mapping is created) and later the record’s path was changed again or the record was deleted. Check the Route Mapping records for a reference to the path you want to use and delete it to free up the path for use.

Routing from One Domain to Another

Your DNS provider may allow you to configure a redirect from your domain to another domain. If this is the case you can do that by entering the URL for the domain you are redirecting to. When doing this you could optionally add a UTM Tracking code to the end of the URL. Anyone coming from that domain who makes a purchase, the UTM code will be attached to their order, making you aware of what domain they went to to arrive at your store.

If you are unable to achieve this with your DNS host, there is another way to achieve this using StoreConnect.

Create a store that runs on the domain you want to route from. This store needs a little bit of configuration:

Anyone who arrives on that site will trigger the redirect that lives in the sites head and arrive at the intended destination. If you include UTM tracking in the URL, any orders placed will contain the UTM code, showing you that they arrived at your store via the other domain.

Migrating to StoreConnect

If migrating an existing site into StoreConnect, you will want to ensure any search engines and external links send traffic to your new site. To make sure this occurs, create your own Route Mapping records to redirect from the old URL to the current URL. This works when your new site is on the same domain as the old as you use relative paths for the redirects. These can also be bulk uploaded using a tool like

A product by default has /products/ before its specified slug to create its relative path. This can be changed by editing the Product2 URL Path setting in your orgs Custom Metadata Types setting from Setup.


Back to Documentation