Hello,
Thank you for contacting Rank Math and bringing your concern to our attention. I’m sorry for the delay and for any inconvenience this issue may have caused you.
If you have already set your posts’ schema as a News Article in Rank Math > Titles & Meta > Posts and in the editor, it is likely generated by one of the plugins or the theme you are using.
To determine that, please follow this troubleshooting guide:
https://rankmath.com/kb/check-plugin-conflicts/
Please let us know if you find the culprit.
Only the site admin would know, and your users won’t be affected by this troubleshooting.
I hope that helps. Thank you, and looking forward to your update.
I have added login details in sensitive data, there is no conflict…
Hello,
That Schema seems to be coming from tagDiv. Please check with your theme provider.
There are two schemas,
one from TagDiv and other from RankMaths…
TagDiv is fine i.e it’s mentioning Blog Article,,,
But RankMaths schema mentions just article type as Article instead of News Article…
That is the issue basically…
Hello,
I checked the URL you provided and it currently shows news article schema as expected, here is a screencast: https://i.rankmath.com/eI8iS2
Please share any other URL with this issue
Looking forward to helping you. Thank you.
It’s showing now, i think, it was cloudflare cache…
Can you tell me if I can USE both news article and blog article schema on a single post?
Hello,
Sorry for the delay.
For using both schemas in your posts, this is not something we would recommend as the two schema sources might lead to a conflict and even confuse search engines, such as Google on what the post is actually about. Google might even end up selecting either of the schema or none.
I hope that helps. Thank you, and looking forward to your update.
Is there a way to remove rankmaths schema on particular categories…
Or can I set different schema for different categories
Hi,
Categories usually use the schema defined in the posts included. If you test any of your category URLs with the RRTest Tool, you will find the schema added the re is the global schema and the schema from your individual posts.
You can however remove posts schema data from all categories by enabling the option in Rank math > Titles & Meta > Categories
For a bit more customized options, you can upgrade to pro to use schema templates and display conditions: https://rankmath.com/kb/rich-snippets/#display-conditions-pro
Otherwise , you can also customize and use this filter: https://rankmath.com/kb/filters-hooks-api-developer/#remove-schema-data-from-posts
Hope this helps you.
Actually I have news site… Some articles are in “News” category and some are in “Blog” category….
I wanna add “News Article” Schema for all posts in “News” categories…
& “Blog Articles” Schema for all posts in “Blog” Category….
Hello,
You can update the default Article type in Rank Math > Titles & Meta > Posts.
However, if you wanted to set the Article type by categories, you may need to do it in the editor for every post:
https://i.rankmath.com/UcNvNj
I hope that helps. Thank you, and please don’t hesitate to contact us if you need further assistance.
FOR EVERY POST!
Does RankMath Pro provides this feature?
Hello,
I had mentioned previously about the display conditions for schema which is a feature available for Pro Users. You can go throuh this article to see if it might fit your needs: https://rankmath.com/kb/rich-snippets/#display-conditions-pro
You can also use this schema filter: https://rankmath.com/kb/filters-hooks-api-developer/#change-post-schema-data and change schema accordingly by using the is_category()
WordPress function.
If you are not a developer, you will have to hire one to do this for you.
Hope this helps.
Can you give me an example to do that…
You can also use this schema filter: https://rankmath.com/kb/filters-hooks-api-developer/#change-post-schema-data and change schema accordingly by using the is_category() WordPress function.
Hi,
Here is an example:
/**
* Filter to change the schema data.
* Replace $schema_type with schema name like article, review, etc.
* @param array $entity Snippet Data
* @return array
*/
add_filter( "rank_math/snippet/rich_snippet_article_entity", function( $entity ) {
if ( in_category('News') ) {
$entity['@type'] = 'NewsArticle';
}
return $entity;
});
Hope this helps. Thank you
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.