Hello,
Thank you for contacting Rank Math.
To add custom fields to your product schema, you can customize and use the following filter:
/**
* Filter to add custom markup for Products.
*
* @param array $entity Snippet Data
* @return array
*/
add_filter( 'rank_math/snippet/rich_snippet_product_entity', function( $entity ) {
$entity['theEntity'] = 'custom value';
return $entity;
});
Hope that helps. If you have any further question(s), please let us know. Thank you.
I found a Schema plugin that was created specifically for this, which makes the process of adding additional product schema fields a lot easier.
The question now is, will Rankmath recognize the new customized schema fields?
Hello,
Thank you for contacting Rank Math and sorry for any inconvenience that might have been caused due to that.
It could work if both of them are not adding the same data. If they are adding the same data, it could create some conflicts but I guess the best option is to try and check since you are adding custom schema content that shouldn’t be in Rank Math.
Looking forward to helping you. 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.