WordPress: Facebook API Change - oEmbed
On October 24, 2020, an API update will cause broken links for Facebook and Instagram feeds across the web.
To fix this and still use oEmbed, users must create a developer account and generate an app ID.
What is oEmbed?
For over ten years, Facebook oEmbed has made it simple for users to share media on websites and social networks without touching any code. Facebook security updates will now require users to get developer app credentials before embedding their content.
What is the Impact of the API Change?
While these changes don't necessarily impact your website, many plugins depend on oEmbed, which will affect unauthenticated content embedded from Facebook/Instagram to break.
How Do I Fix This?
If you notice that the embedded content has broken after the API change, you can install one of the three plugins listed below in the Recommended Plugins section. These plugins help restore Facebook and Instagram embeds either by providing a Facebook developer account and app id, or helping users generate their own.
With WordPress, users have several different choices for addressing this issue, as always. Various plugins have built creative workarounds for the deprecation of oEmbed.
Jetpack collaborated with Facebook directly to handle the generation of developer IDs on the back-end. As outlined in this article, if a user installs Jetpack and links their website to their Facebook account, the plugin will handle the process of registering a developer account on Facebook, creating an app, and generating a token all through their service.
Since Smash Balloon already has a developer account, it has found a way to share it with their users.
From this WP Beginner article: "...Since Smash Balloon has to register an API key to create custom feeds for both Facebook and Instagram, we didn’t need any additional authentication to restore this functionality.”
Users already using Smash Balloon simply have to update their plugin installation, and those who are interested in using Smash Balloon can follow the steps in the video below.
Here are the steps outlined in the video above.
To install Smash Balloon for Instagram:
- Log into your WordPress Dashboard.
- On the left-hand menu, select Plugins.
- Click Add New.
- In the Search box on the right-hand side, type in Smash Balloon.
- You will find two versions of Smash Balloon plugins in the search results – Social Photo Feed (for Instagram) and Social Post Feed (for Facebook). You can use one or both plugins, depending on your website.
- Click Install Now on the Smash Balloon Social Photo Feed plugin.
- Once installed, click Activate.
- On the left-hand menu, you will notice a new tab Instagram Feed. To set up the plugin, hover on this new tab, then select oEmbeds.
- On the Instagram oEmbeds section, click Enable Instagram oEmbeds. This will prompt you to connect to your Facebook account.
- If you're already logged into your Facebook account on your computer, it will ask for confirmation to proceed. Hit Connect to Facebook.
- If you're not yet logged in, it will ask for your Facebook email address and password. Provide this information to connect.
- Once done, your plugin is now connected to your Instagram and Facebook feeds.
To install Smash Balloon for Facebook:
- On the Instagram Feed tab, select Facebook Feed.
- In the pop-up, it will ask to install the plugin. Hit the Install Plugin button.
- It will prompt you that the plugin is now installed and activated.
To use the plugin on your WordPress Posts:
- Go to the Posts section in your WordPress Dashboard.
- Click All Posts.
- Select one of your posts and click Edit.
- Grab a link to one of your Instagram pictures and/or Facebook post and paste it on your WordPress page.
- Click Update on the top right-hand corner to save and publish.
- Your Instagram picture and/or Facebook post should now be seen online. Click View Post to see your updated WordPress page.
This plugin assists users in registering a Facebook developer ID and creating an app to get the API credentials.
How to Create a Facebook Developer Account
- Navigate to Facebook and create your Developer Account.
- Register a Facebook app.
- Add the oEmbed product.
- Generate your App Access Token.
- Once you have generated your Token, oEmbed Plus can be installed and configured.
How to Use oEmbed Plus
- Users should install oEmbed Plus on their WordPress website.
- Navigate to your WordPress Admin Dashboard.
- Choose Settings, then select Writing.
- You will be prompted to provide your App ID and App Secret. Enter these details.
- Click Save Changes.
Once saved, the broken and existing embedded content for your website should continue to work, and new content will use the new APIs going forward.