The JSON-LD (JavaScript Object Notation, Linked Data) encoding is a lightweight data format that can be easy for humans to both read and write. Based on a standard JSON document, JSON-LD adds conventions and annotations for enforcing data conventions.

{ "@context": "https://schema.org/",
  "@type": "WebSite",
  "name": "Schema Markup",
  "url": "https://schemamarkup.app/" }

JSON-LD can also be embedded within HTML documents using <script type="application/ld+json"> tags, which we also support. This often ends up being an easier method of embedding data for web pages that are based on content management systems or external data sources.

<script type="application/ld+json">{
  "@context": "https://schema.org/",
  "@type": "WebSite",
  "name": "Schema Markup",
  "url": "https://schemamarkup.app/"
}</script>

Messages

While decoding JSON-LD data, we generate audit messages to help you understand potential issues and improvements.

  • Lax Syntax — warnings about syntax errors which may cause unexpected behavior.

References

  • Specifications: JSON-LD 1.1
  • Media Type: application/ld+json, application/json
  • Media Type (HTML): application/xhtml+xml, text/html, text/xhtml
  • File Name: *.jsonld, *.json
  • File Name (HTML): *.html, *.htm