Docs    Facebook    Troubleshooting

The shortcode options aren’t working

Shortcode options set before version 4.0 keep working. New customizations use the per-feed options instead.

Would you like to fix a Facebook Feed shortcode that shows the wrong feed or ignores the options you added?

This guide covers the most common reasons a Facebook Feed shortcode misbehaves and how to fix each one.

Since version 4.0, you build each feed in the feed builder. The shortcode names the feed to show, for example the one below.

[custom-facebook-feed feed=1]

When a shortcode shows the wrong feed, an error message, or none of your changes, one of the causes below is usually the reason.

If your site was upgraded from version 3, you may also have legacy feeds. These are feeds from before version 4.0 that still run on a shortcode with no feed number. Their shortcode options work the way they did before. Learn more in Facebook legacy feeds.

Before you get started, make sure Facebook Feed is installed and activated and that you have created at least one feed.

Here is what we will cover.

Checking the Feed ID

To get started, we’ll check that the shortcode names the feed you want. If the feed number is wrong or missing, the feed will not display as expected. To copy the correct shortcode, follow these steps.

  1. In your WordPress dashboard, go to Facebook Feed » All Feeds.
  2. Next, find your feed. The Shortcode column shows its shortcode.
  3. Then click the copy icon beside the shortcode, or open the feed and click Embed. In the Embed Feed window, click Copy.
  4. Finally, paste the shortcode into your page or post in place of the old one, and update the page. For help with the editor, see How to Add a Shortcode in WordPress.

If the shortcode still shows an error, one of the messages below tells you what the plugin can’t find.

It looks like you have more than one feed

This message appears when the shortcode has no feed number and your site has more than one feed. In the free version, it also appears on a site with more than one feed when no feed has the number in your shortcode. Only logged-in administrators and editors see it. Other visitors see no feed.

To fix this, add or correct the number of the feed you want, like this.

[custom-facebook-feed feed=2]

Unless your site was upgraded from version 3, a shortcode with no feed number works only when your site has exactly one feed.

No feed found with the ID

Facebook Feed Pro shows this message, followed by the number from your shortcode, when no feed has that number. Everyone who visits the page sees it.

The free version of Facebook Feed doesn’t show this message. When no feed has the number in your shortcode, it treats the shortcode as if it had no feed number. If your site has more than one feed, logged-in administrators and editors see the It looks like you have more than one feed message instead.

The feed may have been deleted, or the number may have a typo. To fix this, copy the shortcode again from Facebook Feed » All Feeds.

Options Set in the Feed Builder

Every feed except a legacy feed takes its settings from the feed builder. Most options you add to its shortcode are ignored. In the next shortcode, for example, the feed ignores both num and id.

[custom-facebook-feed feed=1 num=10 id=your-page-name]

To make these changes, open the feed in the builder. Next, set the number of posts under Number of Posts on the Customize tab. Then set the Page under Sources on the Settings tab.

A change in the builder applies to every page that shows this feed. To show a different setting on one page only, create another feed with that setting and add its shortcode to that page.

A short list of options does work in the shortcode. When you add one of them, its value replaces the saved setting for that page. Here is an example.

[custom-facebook-feed feed=1 offset=2 class="homepage-feed"]

The options for the Carousel extension also work in the shortcode when that extension is active. To see which options work, go to Which Options Apply to Your Feed. It lists every option and what it does.

Stray HTML Tags in the Shortcode

If you copied the shortcode and pasted it into the Visual editor, it may have picked up HTML tags from the page you copied it from. These tags stop the shortcode from working.

To check, open the Code tab of the classic editor, called Text in older versions of WordPress. In the block editor, open the Code editor instead. Next, look for stray HTML tags inside the shortcode itself. Then delete them and update the page.

Curly Quotes in the Shortcode

If your shortcode includes quotes, check that they are the standard straight quotes (' or ") and not the curly kind (’ or ”). Curly quotes often appear when text is copied from a document or a web page. To fix this, type the quotes again in the editor, like this.

[custom-facebook-feed feed=1 class="homepage-feed"]

Typos in the Option

Every option name must be spelled exactly as it appears in the shortcode reference, and the feed number must be correct. Options must be separated by a space, with no spaces around the equals sign.

That’s it! You now know the most common reasons a Facebook Feed shortcode does not work, and how to fix each one. The shortcode reference lists every option you can add. To keep an older shortcode working, see Facebook legacy feeds.

Frequently Asked Questions

Below, we’ve answered some of the most common questions about shortcode options.

Why does my shortcode ignore an option I added?

Unless it shows a legacy feed, your shortcode takes its settings from the feed builder. Only a short list of options can change them, so change any other setting in the builder. Learn more in Options Set in the Feed Builder.

What happens when an option is in the shortcode and in the builder?

For the options that work in the shortcode, the value in the shortcode replaces the saved setting for that page. The saved setting stays the same for every other page.

Do I need the feed number if I have only one feed?

No. With exactly one feed, a shortcode with no feed number shows it. With more than one feed, add the number of the feed you want.

Do the options in my old shortcode still work after the 4.0 update?

They do for a legacy feed, which is a feed from before version 4.0 that still runs on a shortcode with no feed number. If the update found only one legacy feed, it converted that feed to a feed builder feed instead. Set the options for that feed, and for any new feed, in the builder. Learn more in Facebook legacy feeds.

support

Couldn’t find your answer in the docs?

Contact Support