3

I have a WordPress website with How-To tutorials so I have been putting "How To" schema markup at the top of each post. I am not using any 3rd-party plugins to handle the schema, I'm creating it by hand and injecting the script tag at the top of the WYSIWYG editor in line before the HTML content of the post.

I was going digging through Google Search Console and noticed a new article I posted was pulling the "How To" schema from a completely separate post and I am not sure how this is even possible. I also ran the page through a couple of schema markup tester tools and it's showing the same "How To" scheme from the other blog post.

I have never seen this happen on any of my other sites and I want to keep adding schema markup to all of my old posts but I want to figure out why this is happening before going any further.

3

WordPress uses the top of a post to generate a snippet for a post. When you put the schema markup at the top of the post, WordPress will include that schema any time that it links to that post along with the first few lines of the post. This means that your schema is going to appear on many pages on your site.

For each post that has schema, you should use the <!--more--> tag that tells WordPress where to stop the snippet, and put the structured data below that.

1
  • This was the solution! I resubmitted the affected pages to Search Console to be re-indexed and the issues is all cleared up. Thank you so much! Nov 15 at 6:16
3

Stephen's answer is spot on to fix your current situation. But according to Google's guidelines, structured data written in JSON-LD should be placed in the <head> of the document. So at some point, I would recommend adjusting your workflow to use a plugin that allows you to inject JS in the <head> on a per-post basis.

I would say "if it ain't broke don't fix it", but in this case it seems like it is sort of broken. Perhaps a good time to make that switch? Up to you. Unless of course you're not using JSON-LD, but my instinct is that you are if you're placing at the top of every blog in the wysiwyg editor.

2
  • Thankfully Stephen's answer fixed the issue! I am using JSON-LD and would like to put it in the header but was trying to avoid adding another plugin to the site. Do you have any suggestions on a reliable & lightweight plugin for this? Nov 15 at 7:37
  • Look Up Slim SEO, it's extremely very light weight and well supported. Nov 15 at 13:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.