While working with Facebook’s Sharing Debugger tool you might have encountered an error saying “The following required properties are missing: fb:app_id“ and wondering how to fix it or what it even means.
This error is not just a WordPress error but the whole website community that is checking their sites on the Debugger Tool. In this article we will be discussing how to fix the Error: “the following required properties are missing: fb:app_id” in WordPress.
Don’t worry, in this short and direct article you will know and understand why it’s happening and how to fix it.
Before we go ahead on how to fix it, let’s tackle on why this error is showing and does it affect your website in a way?
Short answer is “NO”, it’s not affecting your website and you can safely ignore this warning.
…but
What is the fb:app_id tag anyway?
The fb:app_id tag is used to be part of Facebook’s product called “Domain insights”. If you use the embedded like (👍) button on your post and your visitors like your content by clicking the embedded Facebook like button, the app_id tag value lets Facebook identify which Facebook Page should be notified and be able to track these statistics.
So why did we suggest that you can safely ignore this warning?
Facebook doesn’t support the “Domain Insights” product anymore. If you’ve heard about Facebook Pixel then you’ll understand why this tag is no longer needed as Facebook Pixel will track anything on your site.
If you’re not sure what Facebook Pixel is and what it means, be sure to read more information here about Facebook Pixel and its uses.
Also, you can read more about Facebook’s decision to stop supporting the “Domain Insights” product on this article.
…still
If you’re bothered with this error every time you use Facebook’s Sharing Debugging Tool and want to “fix” it then continue on the solution below.
I don’t like that this error keeps showing. How to fix the missing: fb:app_id?
Follow the steps below on how to fix the error “The following required properties are missing: fb:app_id“.
1. Create a Facebook App. (Optional)
Skip this first step if you don’t want to create your own APP on Facebook and just want to remove the Facebook app_id error on the Debugger tool.
Before we can add back the app_id property to our website, first we need to have an app_id value. Luckily, Facebook has a default APP ID we can use, which is (966242223397117). This will do the trick.
Alternatively, if you want to use your own APP ID for some reason but you don’t have one yet then make sure to follow this guide on how to create Facebook App first.
2. Add the fb:app_id tag on your website
Before installing any plugin that says it can add the fb:app_id tag property for you easily, we don’t recommend it as it could get conflicted with your present plugins specially if you have plugins for SEO.
Instead, our recommendation is to just simply paste this tiny code snippet into your website. No need for overly complicated and heavy plugins that will potentially cause real issues to your website.
Before you continue on adding the code snippet below, make sure you follow our guide on how to properly add custom code to your website first, where you will learn where to add this code snippet safely.
Copy and paste the code below to your website:
function wptoro_app_id_property() {
$app_id = 966242223397117;
$tag = '<meta property="fb:app_id" content="%d" />';
echo sprintf($tag, $app_id);
}
add_action( 'wp_head', 'wptoro_app_id_property' );
As you can see on the code snippet above, we used Facebook’s default APP ID. If you have your own APP ID then just simply replace its value with your own.
You should have a code snippet in your website that is added and looks like this:
That’s it! This should remove the error when you do the test again. When testing, make sure you click on “Scrape Again” so that Facebook will re-crawl your website and see the new changes you’ve applied.
Conclusion
Well that was an easy fix! But still, if you’ve got any issues along the way and still can’t figure out what’s happening. Just leave a comment below and we will happily help you.
– WPToro Team! ❤️