No input yet.
Migrate inline schema markup to a JSON-LD script block
This converter turns microdata and RDFa Lite in an HTML page into equivalent JSON-LD. Paste the HTML; itemscope and typeof items become schema.org nodes, ready to copy as a script block and already validated.
Last updated:
How it works
Paste the HTML
A whole page or just the fragment with the markup. Nothing in it is rendered or executed – the HTML is only read as text.
Items become nodes
Every itemscope without itemprop (and every typeof without a parent) becomes a top-level node; nested items stay nested; itemid becomes @id.
Copy the script block
Take one block with @graph or one script per item, check the validation tab, then remove the old attributes from the HTML.
Features
Microdata as browsers read it
Values follow the HTML microdata rules: content of meta, src of img and video, href of a and link, datetime of time, value of data and meter, otherwise the visible text with collapsed spaces.
itemref and multiple names
Properties referenced with itemref are collected from anywhere in the page, and an itemprop with several space-separated names fills all of them.
RDFa Lite in the same pass
vocab, typeof, property, resource and prefix are supported, so breadcrumbs written in RDFa end up in the same JSON-LD as microdata products.
Relative URLs resolved
Enter the page address to make relative image and link URLs absolute, as Google requires for images and breadcrumb items.
Validated output
The result runs through the same checks as the JSON-LD validator: unknown types, missing Google requirements and wrong value formats show up before you publish.
Limits & privacy
HTML files can be up to 10 MB; large inputs are converted in a background worker.
The HTML is read as text by a small parser, not by the browser: its scripts and images are never loaded or run. Markup added by JavaScript after loading is not in the source and cannot be found. itemref loops are skipped with a note.
Type and property checks use the schema.org vocabulary (© schema.org sponsors, CC BY-SA 3.0, see licenses). Your HTML is processed in the browser and never uploaded – see the privacy page.
FAQ
Why move from microdata to JSON-LD?
Google supports all three syntaxes equally, but JSON-LD keeps structured data out of the visible HTML. Templates are easier to maintain and markup does not break when the design changes.
Do I have to delete the microdata afterwards?
Mark up each item only once. If the same product is described in microdata and in JSON-LD, remove one of them so search engines do not see two different versions.
What does the content attribute do?
It overrides the visible text, for example content="4.4" on a span that shows 4,4. Google reads it on any element, so the converter does too.
Is full RDFa supported?
RDFa Lite is: vocab, typeof, property, resource and prefix. Attributes of full RDFa such as about, rel and datatype are ignored and listed in the notes.
Are values converted to numbers?
No. Microdata has no data types, so every value stays a string, exactly as search engines read it; "119.99" is a valid price.