How to add schema markup to website

Adding schema markup to your website can help search engines understand your content better and improve your website’s visibility in search engine results pages. Here are some steps to add schema markup to your website:

  1. Determine the best schema for your content: Before you begin coding and implementing your schema, you need to know which schema properties to use. Schema properties are the specific attributes you assign to parts of your content within the schema. Using the Article schema, for example, you’d want to give search crawlers details about: Your article headline The date it was published The article author The article’s body content Each one of those would be a property within your schema. We recommend checking out the documentation on Schema.org to get all the properties you need.
  2. Choose a schema format: There are three different schema formats you can choose from. These include:
    • JSON-LD (JavaScript Object Notation for Linked Data)
    • Microdata
    • RDFa (Resource Description Framework in Attributes)

JSON-LD is the most popular schema format for SEO and the one we will use in this tutorial. It’s easy to implement and maintain and allows you to add multiple schema types on a single page, all of which are ideal for helping search crawlers understand your site.

  1. Identify the relevant schema properties: Before you begin coding and implementing your schema, you need to know which schema properties to use. Schema properties are the specific attributes you assign to parts of your content within the schema. Using the Article schema, for example, you’d want to give search crawlers details about: Your article headline The date it was published The article author The article’s body content Each one of those would be a property within your schema. We recommend checking out the documentation on Schema.org to get all the properties you need.
  2. Code your schema: Now that you’ve got all the pieces in place, it’s time to assemble them to create your schema code. Here, you see a complete article schema written using JSON-LD formatting. Let’s look at how we put this together.

JSON

<script type=”application/ld+json”>

{

  “@context”: “https://schema.org”,

  “@type”: “Article”,

  “headline”: “Article headline”,

  “datePublished”: “2024-02-06”,

  “author”: {

    “@type”: “Person”,

    “name”: “Author name”

  },

  “publisher”: {

    “@type”: “Organization”,

    “name”: “Publisher name”,

    “logo”: {

      “@type”: “ImageObject”,

      “url”: “https://www.example.com/logo.png”

    }

  },

  “image”: {

    “@type”: “ImageObject”,

    “url”: “https://www.example.com/image.jpg”,

    “width”: 1200,

    “height”: 800

  },

  “description”: “Article description”

}

</script>

AI-generated code. Review and use carefully. More info on FAQ.

  1. Add the schema code to your website: Once you have created your schema code, you need to add it to your website. You can add the code to the head section of your HTML document or use a plugin to add the schema code to your website.

By following these steps, you can add schema markup to your website and improve your website’s visibility in search engine results pages.

I hope this helps! Let me know if you have any other questions.

Learn more

1seochatter.com2ahrefs.com3neilpatel.com

Leave a Comment