Core writing
How to Validate JSON-LD Before You Publish
Syntax, schema.org shape, and Google eligibility are three different checks. Use them in that order, then confirm the markup matches the visible page.
On this page
Validating JSON-LD before you publish is three checks, done in order. The text has to parse as JSON. The node has to match schema.org for the type you named. Google has to still offer a rich result for that type, the required properties have to be present, and those properties have to match the page a person can read.
SchemaDesk’s checker does the first two for the types in the form. It builds the object, confirms that the object is legal JSON, and checks the shape it knows: required fields, absolute URLs, numeric prices, and dates. For FAQ and How-To it then labels the result as valid schema.org that Google no longer displays. It does not replace the Rich Results Test or the Schema Markup Validator. Those tools cannot be prefilled by a third-party site. You copy the script and paste it, or you give the Rich Results Test the public URL and let it fetch the page.
A status that calls the markup valid is eligibility, not a place on the search result. That includes the generator line “Valid. Google may consider this.” Google still has to crawl a URL people can open, and it can still show an ordinary blue link. This routine is current on 25 October 2026.
Which tool owns which check
The first check is mechanical. JSON has no comments, no trailing commas, and no single-quoted strings. A curly quote, a trailing semicolon, or a template token such as undefined fails the parser before any vocabulary is considered. Neither official tool can judge the type until this check passes.
The second check is the vocabulary. @context should be https://schema.org, and @type should be the type you meant. Properties have to belong to that type, and URL values have to be absolute http or https URLs. SchemaDesk applies this to the fields on its form. It does not walk the whole schema.org vocabulary. For that reading, paste the script into the Schema Markup Validator.
The third check is Google. A rich result for that type still has to exist, the properties it requires have to be present, and those properties have to match the visible page. The appearances Google still documents are in the search gallery, updated 16 October 2026. FAQ rich results ended on 7 May 2026, including for government and health sites. That date is on the Search documentation updates page. How-To rich results ended in 2023. The August post is How-To and FAQ changes. On 14 September 2023 Google removed the How-To documentation because the result was no longer shown on desktop or mobile. A clean FAQPage or HowTo node can pass check two and fail check three.
What the on-page checker will say
Read the status card before you copy. “Not valid yet” means an error is still open: a recipe with no image, a price that is not numeric, a crumb without a URL, a question with no answer.
Warnings are not errors. On a recipe, an empty author, yield, prep time, or cook time is a warning. Nutrition is optional, and only worth adding when the page shows it. A warning can sit under “Valid. Google may consider this.” Fill it from the page or leave it empty on purpose. Do not invent a calorie count to clear the line.
“Valid schema.org. Google no longer shows this rich result.” is the FAQ and How-To outcome. Keep that node only if some other consumer reads it. Under the eligible status, the promise is narrower: eligibility is not a promise that a rich result will appear, and the markup still has to match the visible page. The checker never fetched your site.
Syntax errors, thin nodes, and retired types
A syntax error is text that is not JSON. A comma after the last property, a // comment, a smart quote, or a raw line break inside a string will do it. So will a template that turns quotes into " inside the script. The element has to use type="application/ld+json". application/json, or a bare object with no script element, is not a JSON-LD block.
A missing required field is legal JSON of the wrong shape. A recipe with a name and no image, no ingredients, or no instructions is not eligible for a recipe rich result. SchemaDesk reports those as errors. A missing recommended field is quieter. The node can still be the right type, and any result Google shows may be thinner. Fill recommended fields that the page already states. Leave the others empty.
A retired type can be excellent schema.org and still have nothing to show. On 25 October 2026 that is FAQPage and HowTo. The Schema Markup Validator may accept them. That is check two succeeding. It will not restore an FAQ accordion. Failures that look like “Google ignored my markup” are often not syntax. Relative image URLs, empty offers, facts the page does not show, and entities that disagree are covered in JSON-LD mistakes that keep rich results from appearing.
Publish in this order
- Generate the node from the page you are publishing. For a recipe, use the recipe form and enter the name, image URL, ingredients, and steps the HTML already shows. Sample values are fiction. Leave them in and the script describes a different page.
- Read the status card. Fix every error. Fill a warning from the page, or leave it empty on purpose.
- Use Copy script so the type attribute comes with the object. Paste it once into the template for this URL. A second copy in a layout does not raise eligibility. It can disagree with the first.
- Publish, then view source on the public URL. Confirm the script survived, the type attribute is intact, and the quotes are still quotes.
- Run the Rich Results Test on that public URL, or paste the script. SchemaDesk cannot open the test with your markup already loaded. No third-party site can. Use the Schema Markup Validator when you want the vocabulary reading. That tool is check two. The Rich Results Test is check three.
- After Google recrawls, read the rich-result report in Search Console on the property that owns the production host. Those reports list pages Google processed, not every URL you pasted into a test. Several days is a normal wait. Absence during that wait is not a new syntax error.
How a fetched page becomes nodes, including more than one script on the same URL, is covered in how Google parses JSON-LD.
View source when JavaScript injects the script
View source is the HTML response. The Elements panel is the DOM after scripts run. You need both when a tag manager or a front-end script inserts the JSON-LD.
If the script is in the raw HTML, the node exists before rendering. Confirm that with view source. Then look at Elements, because a later script can remove the block, and a rendering crawler may keep the rendered DOM.
If the raw HTML has no JSON-LD, rendering has to succeed. DevTools can show a script that view source never had. The injector must not wait for a click, a consent banner the crawler will not accept, or a script the public host blocks. Fetch the public URL in the Rich Results Test and fetch the raw response yourself. If they disagree, put the script in the HTML, or prove the render works on the URL you ship.
A green test, and a staging host
A green Rich Results Test means the page is eligible for a feature Google might show. It does not rank the URL, and it does not reserve the snippet. Critical errors block eligibility. Other notes are quality issues, not a switch that forces the appearance.
Match the screen before you treat green as finished. An image URL that loads in the test while the page shows a different photo is a mismatch. A price that is fresh in the JSON and stale on the screen is a mismatch. Google’s structured-data guidelines require the markup to describe content readers can see.
Search Console reports show pages Google processed. A valid test on a staging URL that robots.txt blocks proves the snippet can be parsed. It proves nothing about production. The same is true of a staging host that sends noindex or requires a login, and of a staging template that is not the one you ship. Test the public URL a visitor gets, then read Search Console on that host after recrawl.
A recipe script you can read against the page
This soup is fictional, and it lives on example.com. It parses, the type is Recipe, and the name, image, ingredients, and instructions are the fields SchemaDesk treats as the gate for a recipe rich result. Author and yield are present because this imaginary page shows them. Prep time is omitted on purpose: that is a warning, not a syntax error, when the page omits it too. Build the real page in the recipe generator and publish that script, not this sample.
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Recipe",
"name": "Red lentil soup with tomato",
"image": "https://example.com/images/lentil-soup.jpg",
"description": "A one-pot lentil soup. Fictional recipe, used here only as a markup sample.",
"recipeYield": "4 servings",
"recipeIngredient": [
"200 g red lentils",
"1 onion, chopped",
"400 g canned tomatoes",
"1 litre water"
],
"recipeInstructions": [
{
"@type": "HowToStep",
"text": "Rinse the lentils in cold water."
},
{
"@type": "HowToStep",
"text": "Simmer the lentils, onion, tomatoes, and water for 25 minutes."
}
],
"author": {
"@type": "Person",
"name": "R. Mehta"
}
}
</script>
Checklist
- The script parses as JSON: no comments, no trailing comma, straight quotes, type
application/ld+json. - The status card is not “Not valid yet.” Each warning is filled from the page or left empty on purpose.
- FAQ and How-To show the schema-only label. You are not waiting for those rich results to return.
- Copy script was pasted once into the template that renders the public URL.
- View source on that URL shows the script. If JavaScript injects it, you know the raw HTML has no JSON-LD, and rendering succeeds without a click.
- The Rich Results Test ran on the public URL. The Schema Markup Validator was used when you needed the vocabulary reading.
- The strings match the screen, including the image that actually loads.
- Search Console is read after recrawl, on the production property, not from a robots-blocked staging URL.