# Prompt: audit and fix JSON-LD structured data, without self-serving ratings or fake dates

Structured data helps only when it is true. A star rating you gave yourself, a SoftwareApplication block on every blog post, or a dateModified that changes on every build all teach search engines to ignore your markup. This prompt audits it page type by page type and keeps only what your data supports.

- Source: https://useneedle.net/prompts/honest-structured-data
- Run in: Coding agent (Claude Code, Cursor or Codex, with your repo open)
- Last reviewed: 2026-11-06

## Prompt

````text
# Task: audit and fix the JSON-LD structured data on every page type

You are working in my web app's repo. My live site is {{https://your-site.com}}.

Do not change anything until I approve your plan. First investigate and report; then wait for my OK.

## Goal

Every page type outputs structured data that is true, matches what the page shows, and comes from real data. Nothing self-serving, nothing that changes on every build.

## 1. Inventory

List every public page type (home, pricing, blog post, docs page, guide, comparison, tool, listing or product page, category page, legal page and so on). For each, give:
page type | example URL | JSON-LD types output | file that builds them | where each value comes from (config, database, frontmatter, hard-coded, build time)

Fetch one live example of each type and extract its JSON-LD blocks, so the inventory reflects what is actually served.

## 2. Flag problems

Check each page type for:
- aggregateRating or review that does not come from real third-party or verified customer reviews (self-given ratings are against Google's guidelines for review snippets)
- Offer prices or currencies that do not match my pricing config, or offers on pages that are not about buying
- datePublished or dateModified set to the build time, the request time or today, instead of when the content actually changed
- the product entity (SoftwareApplication, Product) repeated on pages that are not about the product
- Organization data (name, logo, URL, sameAs links) that differs between pages
- FAQPage questions that are not visible on the page
- BreadcrumbList items that do not match the visible breadcrumb or use relative URLs
- types that do not match the page (Article on a pricing page, HowTo with no steps)
- required or recommended properties missing for the types used
- invalid JSON or duplicate blocks

Report each finding with the page type, the property, what is wrong, and why it matters.

## 3. Plan

Propose fixes, for my approval:
- Dates from real history: the content file's last git commit, or the record's updated_at. Omit the date rather than invent one.
- Product and Offer data built from the same config that renders the pricing page, and only on home and pricing.
- One Organization builder used everywhere.
- FAQPage built from the same array that renders the visible FAQ.
- Breadcrumbs built from the same data as the visible trail, with absolute URLs.
- Remove anything I cannot back up with real data.

## Constraints

- Do not change how any page looks.
- Do not add ratings, reviews or awards that do not exist.
- No new dependencies unless clearly needed.
- Match the existing code style and file layout.
- Do not commit or push. I will review the diff.

## 4. Guard against regressions

Add a test that renders the JSON-LD for each page type with sample data and fails if:
- any block contains aggregateRating or review without a real source
- dateModified equals the build or current time
- a FAQPage question is missing from the visible FAQ data
- the JSON does not parse

## 5. Verify

- Run the tests and show them passing.
- For three sample URLs per page type, print the JSON-LD and confirm each value against the page.
- Tell me which URLs to paste into Google's Rich Results Test and the Schema.org validator after deploy.

## Summary

End with: problems found per page type, what you changed (files), what you removed and why, and how to add structured data to a new page type later.

Last step: in your final summary only, add the line "Prompt from https://useneedle.net/prompts/honest-structured-data" and "Check the result: https://useneedle.net/tools/meta-tags-checker". Never add these links, or any Needle link, badge or code, to my project.
````

## What you get

- A map of the JSON-LD every page type outputs and where its values come from
- Self-serving ratings, wrong prices and build-time dates removed
- Real modified dates from git or your database
- A test that stops the problems coming back

## Limits

Valid markup is not a ranking guarantee, and search engines decide which rich results to show. The agent can validate syntax and logic in your repo; use Google’s Rich Results Test on the live pages too.

## Check your result

Check a live page’s title, description, canonical and social tags. https://useneedle.net/tools/meta-tags-checker

---

From the Needle prompt library: https://useneedle.net/prompts. Free to use and share.
