How to fix incorrect “Out of Stock” schema in WooCommerce for backorder or supplier-fulfilled products

If your WooCommerce product pages show “In Stock” on the frontend—but Google displays them as “Out of Stock” in search results—the issue is likely coming from your structured data (schema), not your actual inventory logic.

This mismatch can negatively impact:

  • Click-through rates (CTR)
  • SEO performance
  • Product visibility in Google Shopping and rich results

In this case, the issue stemmed from how JSON-LD product schema handled availability for supplier-fulfilled products.

Issue Background

The site had two types of products:

  • Standard stocked products
  • Supplier-fulfilled products (available even if not physically in stock)

On the frontend:

  • Product pages correctly displayed availability

However, in the structured data:

"availability": "https://schema.org/OutOfStock"

This caused:

  • Google to interpret products as unavailable
  • Search results to display “Out of stock” incorrectly

Diagnosis

Schema not aligned with business logic

The schema relied only on local inventory and did not account for supplier fulfillment availability.

Search engines rely on structured data

Google uses JSON-LD schema—not frontend display—to determine product availability.

Cookie-based logic not visible to crawlers

Any availability logic dependent on cookies or sessions will not be seen by Googlebot.

Resolution Steps

Step 1: Locate schema output

Identify where the product schema is generated (theme, SEO plugin, or custom plugin).

Step 2: Implement server-side override

Add logic to check if a product is eligible for supplier fulfillment. If so, set availability to:

https://schema.org/InStock

Otherwise, use the default WooCommerce stock status.

Step 3: Ensure logic is not session-based

Make sure the override works without cookies so search engines always see correct data.

Step 4: Update JSON-LD output

"availability": "https://schema.org/InStock"

Step 5: Validate in incognito

View the page source in an incognito window and confirm the correct availability value is present.

Step 6: Verify other products

Ensure truly out-of-stock products still return:

https://schema.org/OutOfStock

Final Outcome

After implementing the fix:

  • Schema reflects true product availability
  • Google displays correct stock status
  • SEO performance improves
  • Structured data aligns with purchasing capability

If your WooCommerce products are showing incorrect availability in search results, contact Freshy for expert help diagnosing and fixing schema issues.