How to Automatically Create Redirects for Archived Products
Automatically create a 301 redirect URL whenever a product's status changes from active to archived, ensuring customers never hit a dead link.
The Problem
Forgetting to set up redirects when you archive a product is a common, costly mistake. Each forgotten redirect leads to a frustrating 404 "page not found" error for your customers, hurting their experience and your SEO ranking. Manually tracking and creating these redirects is a tedious, error-prone task that eats into valuable operational time.
What This Automation Solves
This Flow eliminates manual work by triggering automatically when a "Product status updated." It then checks the "Old status ACTIVE AND Product status ARCHIVED" condition, ensuring it only acts on truly archived products. Finally, the "Create redirect URL" action instantly sets up a 301 redirect from the old product page to your desired new location, such as the collection page or homepage.
When to Use This Automation
- You frequently archive out-of-stock, seasonal, or discontinued products.
- You want to maintain strong SEO and prevent dead links from hurting your search rankings.
- You aim to provide a seamless customer experience, avoiding frustrating 404 "page not found" errors.
Workflow
Trigger
Step 1Starts when a product's status is updated
Condition
Step 2Condition checking if the status changed from active to archived
Action
Step 3Create a redirect URL for the archived product
Step-by-Step Setup
- 1
Start with the "Product status updated" trigger.
- 2
Add a Condition: Check if the "Product old status" is `ACTIVE` AND the "Product status" is `ARCHIVED`.
- 3
Add an Action: Select "Create redirect URL."
- 4
Configure the redirect: Use the archived product's URL as the `Path` and choose a relevant new destination (e.g., `/collections/all` or your homepage `/`).
Related Questions
- What's the best destination for an archived product's redirect?
- Redirecting to a relevant collection page, category page, or your store's homepage provides a good user experience and helps retain link equity. Avoid redirecting to another product if it's not a direct replacement.
- How do 404 errors impact my store's SEO?
- Frequent 404 errors signal poor site maintenance to search engines, potentially leading to lower search rankings and a wasted crawl budget, making it harder for customers to find your active products.
- Can I redirect archived products to a different page based on product type?
- Yes, you can add an additional condition to this Flow (e.g., "Product type is 'Apparel'") before the redirect action, allowing you to send specific product types to different destination URLs.
- Does Shopify automatically create redirects when I archive a product?
- No, Shopify only creates automatic redirects if you change a product's URL handle while it's still active. Archiving a product requires manual redirection or this specific Shopify Flow to prevent 404 errors.
Recommended Tools & Apps
Launch this automation
Open Shopify Flow and use this page as your setup blueprint.
Merchant Insight
Instead of always redirecting archived products to your homepage, consider sending them to a relevant collection page. This keeps customers engaged with similar products, improving their experience and your chances of a conversion.
Related Automations
Auto-tag Products When Added to Your Sale Collection
Automatically applies a 'Sale' or 'Clearance' tag to products the moment they are added to your designated sale collection, streamlining merchandising.
How to Automatically Tag Products by Vendor
Automatically apply vendor-specific tags to newly created products, streamlining catalog organization and enhancing filtering capabilities for your store.
Automate 'New Product' Tag & Collection Removal
Automatically manage your product lifecycle by tagging new products, waiting a set period, then removing the 'New' tag and relevant collection placements.