How to set custom Open Graph tags
Yoast SEO includes the option to set custom Facebook images, titles and descriptions on a page by page basis after you have enabled OpenGraph meta data.
Table of Contents
WordPress has two options for your homepage: Your latest posts or static. Setting custom Open Graph tags will depend on which option you selected.
Check Homepage Type
- Log in to your WordPress website. When you're logged in, you will be in your 'Dashboard'. On the left-hand side, you will see a menu. In that menu, click on 'Settings'.
- The ‘Settings’ menu will expand providing you additional options. Click on 'Reading'
- The first option is 'Your homepage displays'.
- If 'Your latest posts' is selected, follow the steps here.
- If 'A static page' is selected, follow the steps here.
Homepage Displays Your Latest Posts
- Log in to your WordPress website. When you're logged in, you will be in your 'Dashboard'. On the left-hand side, you will see a menu. In that menu, click on 'SEO'.
- The ‘SEO’ settings will expand providing you additional options. If you don't see the 'Social' setting in your 'SEO' menu, please enable your advanced settings first.
- Click on 'Social'.
- Click on the Facebook tab.
- Enter a custom image, title and description under Frontpage settings.
- Click 'Save Changes'.
Posts, Pages and other Taxonomies
The social tab of the meta box allows you to set a custom image, title and description on each post, page (including the static front and blog pages) or taxonomy.
One of the Yoast SEO for WordPress Premium features is the ability to see what your post will look like when sharing on Facebook.
Available Developer Filters
There are a number of filters documented in the plugin code for developers to programatically change OpenGraph output. Here are some examples.