Temporary or permanent: the first question
When a product is unavailable, the SEO decision comes down to one question: will it be back on sale? Three scenarios follow, each handled differently.
- Temporarily out of stock: the product will return, even without a confirmed date. The page stays online.
- Replaced: a new model or version serves the same search. The old page redirects or points to the new model.
- Permanently discontinued: it won't return and has no direct replacement. You choose between a redirect to a relevant page and a 404 or 410 response.
The most common mistake is treating every case the same: deleting every product that hits zero stock or, the other way round, leaving pages for items that will never return online for years. The first throws away accumulated rankings and links; the second fills the catalogue with pages that disappoint search visitors.
Temporarily out of stock: keep the page
If the product is coming back, the page must stay reachable with a 200 status and remain indexable. It already has history, internal links and possibly external ones: removing it for a few weeks means starting from scratch when stock returns.
What to show on the page
- A clear status next to the price: "Out of stock", with the restock date if you know it.
- A back-in-stock alert form connected to your email tool.
- Two or three similar products that are available, above the fold on mobile.
- All the original content: description, specifications, reviews. A page stripped down to a "not available" message risks being read as a soft 404.
In collections you can push it to the bottom of the sort order instead of removing it, so it remains a useful internal link for crawling. Internal links from collections and filters are covered in our article on Shopify collections and filters SEO.
Replaced by a new model
If the new model meets the same need, a 301 from the old page to the new one is the cleanest option. In its status code documentation, Google describes a permanent redirect as a strong signal that the target should be processed instead of the original.
There is one exception worth considering. If the old page still has its own demand, for example customers looking for the old model's manual, spare parts or compatibility, it may be better to keep it online with a prominent notice and a link to the new model. The page then keeps serving existing buyers, and the availability in structured data becomes Discontinued.
Permanently discontinued: 301, 404 or 410
For a product that won't return and has no direct replacement, there are two routes.
A 301 to a relevant page
This makes sense when there is a destination that satisfies people looking for that product: a very similar item or the category it belonged to. Google's site move guide warns, however, against redirecting many old URLs to a single irrelevant destination such as the home page, as it can confuse users and may be treated as a soft 404.
404 or 410
If there is no sensible destination, the page should return an error. According to Google Search Central, all 4xx codes except 429 are treated the same way: the URL is removed from the index. A 410 states more explicitly that the removal is intentional but has no documented advantage over a 404. Customize your error page with search and main categories.
To decide case by case, look at three data points: organic clicks over recent months, external links to the page, and whether a real alternative exists. The reasoning we use for content pruning of articles applies to product pages too.
Availability in structured data
Structured data must reflect the real status. In Google's merchant listing documentation, the offers.availability property takes values from the schema.org ItemAvailability vocabulary, including:
InStock: available to buy now.OutOfStock: currently unavailable.BackOrder: can be ordered for later delivery.PreOrder: can be reserved before release.Discontinued: no longer made or sold.
Google accepts one value per offer. Make sure the markup updates together with stock: an out-of-stock product still marked InStock also creates mismatches with your Merchant Center feed. If you generate markup from the catalogue, the logic is the one described in our guide to dynamic schema markup.
Handling it on Shopify
On Shopify the behaviour depends on a few settings.
- Temporary stockout: with inventory tracking on, at zero quantity the product can't be added to the cart but the page stays live. The "Continue selling when out of stock" option lets you take orders at zero stock; in that case the correct availability is
BackOrder, notInStock. - Removed product: setting the status to Draft or removing the product from all sales channels makes its URL return 404.
- Redirects: create them under Content > Menus, View URL Redirects, Create URL redirect. Shopify states that redirects only work for URLs that return 404, so draft or delete the product first and then create the redirect. For many URLs there is a CSV import.
Watch the order of operations: a redirect created while the product page is still active won't fire. Our Shopify technical SEO guide covers the other settings that affect crawling.
Monitoring the impact
After every catalogue change, check the page indexing report in Google Search Console, especially "Not found (404)" and "Soft 404". The latter flags pages that return 200 but look empty or like an error. Spot-check redirects with a tool that shows the status code, and avoid redirect chains created by successive replacements.
If you run a Shopify catalogue that changes often and want clear rules for stockouts and discontinued items, we can help through our Shopify ecommerce setup service.
- prodotti esauriti
- seo ecommerce
- redirect 301
- errore 404
- dati strutturati
- shopify seo
- catalogo prodotti
Frequently asked questions
Should I noindex out-of-stock products?
Not if they are coming back. The page keeps its rankings and links, and visitors can sign up for a back-in-stock alert or pick an alternative. Noindex only makes sense in special cases, such as products that won't return but that you want existing customers to still be able to consult.
404 or 410 for a deleted product?
Google treats them the same: Search Central documentation says all 4xx errors except 429 are handled alike and the URL is removed from the index. A 410 simply states more explicitly that the removal is intentional.
Can I redirect deleted products to their category?
Yes, if the category genuinely offers alternatives to people looking for that product, as in Shopify's example of redirecting a deleted t-shirt to the t-shirts collection. Redirecting many URLs to a page with little relevance, such as the home page, may be treated as a soft 404.
Which availability value should I use in structured data?
The real one: InStock, OutOfStock, BackOrder if you accept orders for later delivery, PreOrder before launch, Discontinued if the product is no longer made or sold. Google accepts only one value per offer.
Sources
- How HTTP status codes, and network and DNS errors affect Google Search — Google Search Central
- Site moves with URL changes — Google Search Central
- Merchant listing (Product, Offer) structured data — Google Search Central
- ItemAvailability — Schema.org
- Creating URL redirects — Shopify Help Center
- Selling when out of stock — Shopify Help Center
Related articles
Technical SEO · 9 min read
Technical SEO Optimization for Shopify Collections & Product Filters: Indexing & Crawl Budget
Learn to tackle Shopify indexing and crawl budget issues by optimizing collections and product filters. A practical guide to avoid duplicate content, improve rankings, and boost conversions.
Technical SEO · 6 min read
Dynamic Schema Markup for eCommerce: Scalable Implementation for SEO and AI
Learn how to implement dynamic schema markup for your eCommerce. Enhance SERP visibility with attractive rich results and optimize your product catalog's understanding by AI algorithms, boosting qualified traffic and
Technical SEO · 6 min read
SEO content pruning: when to update, merge, noindex or remove articles
A cautious method for evaluating content, protecting links and organic demand, choosing the right action and rolling out changes with measurement and rollback.
