Unable to remove og:decription or twitter:description when data is blank

#756067
  • Resolved Samrat Singh
    Rank Math free

    Hi Team,
    We are facing one issue on the og:decription and twitter:decription is added unnecessary even if the meta description of the page is blank. OG descriptions are automatically added. Please let us know the fix for the same.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello,

    I apologize for the issue you are facing with the og:description and twitter:description being added unnecessarily even when the meta description of the page is blank.

    In this case, if the meta description is blank, Rank Math automatically adds a default description to ensure that the tags are present. Unfortunately, there isn’t a direct option to remove these descriptions when the data is blank.

    If you wish to have more control over these descriptions, you can consider adding a custom description to your pages to override the default behavior. This will allow you to provide specific descriptions for each page.

    If you have any further questions or need assistance with this, please feel free to reply to this ticket, and one of our human agents will assist you promptly.

    Thank you for bringing this concern to our attention.

    Sources:
    How to Fix the ‘og: image’ Property Should Be Explicitly Provided » Rank Math
    Social Media Options in Rank Math
    Open Graph Meta Tags » Rank Math

    Still no reply came from human. I need the genuine reply whether it is possible or not.

    Thanks

    Hello,

    Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.

    Rank Math only generates the og:description and twitter:description meta tags when the meta description tag is added. However, if you want to remove these meta tags, you can use the following filter on your website:

    add_filter( 'rank_math/opengraph/facebook/og_description', '__return_false');
    add_filter( 'rank_math/opengraph/twitter/twitter_description', '__return_false');
    

    Here’s how you can add filter/hook to your WordPress site: https://rankmath.com/kb/wordpress-hooks-actions-filters/

    Let us know how it goes. 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.

Viewing 3 replies - 1 through 3 (of 3 total)

The ticket ‘Unable to remove og:decription or twitter:description when data is blank’ is closed to new replies.