Sharing posts from WordPress to Facebook is pretty easy. There are dozens of social sharing plugins that make the process quick and painless.
Sometimes the image used when sharing a post can cause problems though.
When you share a post from WordPress that has a featured image Facebook uses that as the image for its post. However, what happens when the post doesn’t have an image?
If there is no featured image or the post doesn’t have any images, Facebook will try to use your website’s logo or header image if you have one. This usually looks pretty bad.
Logos and header images are not meant to be used as an image for sharing on Facebook so they can become stretched or blown up when shared.
A more extreme example below shows a header image that was used when the post was shared to Facebook. Only a small section of the image is used and it looks pretty bad.
Ideally you want a post like the example below. A custom image that will be used when a post or page contains no images.
No more ugly stretched images on your Facebook posts.
To fix this problem you need to create a default image to be used when posts have no image. The default image will be used instead of your logo or header image.
Create the custom image with Photoshop or an online tool like Canva for your default image. The image should be at least 1200 x 630 pixels.
Setting the default Facebook image
The Yoast SEO plugin makes it super easy to set a custom image to use when sharing posts to Facebook.
After installing and activating the plugin go to SEO then Social within your admin dashboard. Click the Facebook tab and scroll down to Default Settings. Upload or select your custom image from the media gallery.
Now that image will be used any time a post without images is shared to Facebook.
Override images on specific posts
Yoast can also be used to override the Facebook image on a per post basis. This is useful if you don’t want to use the featured image or default image.
In the WordPress post editor scroll to the bottom of the page and find the Yoast SEO section. Click the social icon, find the Facebook Image section, and upload an image or select one from the media gallery. From here the post title and description can also be overridden.
Now you no longer have to worry about images becoming cut off or blown up when posts from WordPress are shared to Facebook.