When using Google's Structured Data Testing Tool, I consistently get the error:
The URL could not be rendered. Some markup may be missing.
I have identified and fixed all of the structured data errors - I have 3 items, all of which have 0 errors, two of which have 0 warnings and one of which has 3 warnings.
I am using OpenGraph vocabulary (both
og:
andtwitter:
) in the first item and schema.org vocabulary in both subsequent items.I am using
<meta>
elements in the<head>
to structure the data in the first item andjson-ld
to structure the data in both subsequent items.I have checked to see if the document markup validates on W3 Unicorn - it does.
Since the markup validates and the structured data is error-free, what does it mean when Google Structured Data Testing Tool consistently informs me:
The URL could not be rendered. Some markup may be missing.
The URL could not be rendered in what sense?
Update:
After further testing, I have established the following:
- The error is definitely being triggered by the markup inside the
<body>...</body>
of the document. - There are multiple (as yet unknown) elements triggering the error.
- One of the errors is definitely the presence of a
<footer>...</footer>
element. A<body>
which contains a<header>
or a<main>
(or both) will not trigger the error, but as soon as the<body>
contains a<footer>
, it will. - One of the errors is an anchor which contains a class (eg.
<a href="/my-page" class="link-to-my-page">My Page</a>
) - when theclass
attribute is removed from the anchor, the anchor no longer triggers an error. - One of the errors is the presence of one or more
<article>...</article>
elements. As soon as the<body>
contains at least one<article>
, it will trigger the error. - One of the errors is any
<img>
element which references an SVG. If thesrc
attribute points to a file which has an identical file-path but ends in.png
, the error is not triggered.
Lightbulb Moment
- The
<img>
element in 6. points to an SVG. - each
<article>
has a CSSbackground-image
which is an SVG - The
<a>
which contains the class has a CSSbackground-image
which is an SVG - The
<footer>
has a::before
and an::after
pseudo-element, each of which has a CSSbackground-image
which is an SVG
Conclusion
Google Structured Data Testing Tool doesn't yet know how to process (or just ignore) references to SVG files.