Streamline Your Schema.org Single Script Solution
![]() |
Have you ever found yourself adding multiple Schema.org declarations to your website and noticed something? Each time, you're opening a brand new <script> tag, adding your information, and then closing it. For me, seeing three separate <script> tags for different Schema.org bits felt a bit repetitive. It's like opening a new book for every single sentence!
Beyond just how it looks, I also had this strong feeling that combining them into a single script tag would be better for my site's speed and overall Search Engine Optimization or SEO. Now, I'll be honest, I'm not a total expert on the nitty-gritty of SEO, but in my mind, faster loading is always a good thing for search engines!
For a while, I thought combining them wasn't even possible. But after days of searching the internet, I finally stumbled upon a brilliant solution. And now, I'm excited to share it with you!
So, if you're like me and want to tidy up your Schema.org setup, here's how you can place multiple objects inside of an array within a single application/json-ld script tag. A huge shout-out goes to Jeff Jack, who shared this clever method in a comment on Will Hattman's post titled "How to Combine Multiple Schema.org Itemtype Declarations in a Single Script." Let's dive in!
[ { "@context”:”http://schema.org/", "url":”https://www.example.com/", … }, { "@context":"http://schema.org/", "url":"https://www.isentress.com/", … }, { "@context":"http://schema.org/", "url":"https://www.isentress.com/", … } ]
I tried it and tested using https://developers.google.com/search/docs/advanced/structured-data and got no problems.
- Hattman, W. (2017, March 22). How to combine multiple Schema.org Itemtype declarations in a single script. UpBuild. https://www.upbuild.io/blog/how-to-combine-multiple-schema-org-itemtype-declarations-in-a-single-script/
- Search Engine Land. (2020, April). mark html schema structured data [Photograph]. Retrieved from https://searchengineland.com/figz/wp-content/seloads/2020/04/mark-html-schema-structured-data-SS_1089903890-1920x1080-1.jpg