Open Graph Tags

10-20 minBeginner

Open Graph (OG) tags control how your content looks when shared on Facebook, LinkedIn, Discord, and Slack. A compelling card increases referral traffic significantly.

Prerequisites

  • WordPress admin access
  • Featured images set
Easy Recommended

Using Yoast SEO

Automatically uses your SEO Title/Description and Featured Image unless overridden.

1

Enable Social Features

1

Go to Yoast SEO > Settings > Site Features > "Social sharing"

2

Toggle ON

2

Set Default Image

1

Go to Yoast SEO > Settings > Site basics

2

Upload a "Social sharing image" (1200x630px)

3

This acts as a fallback for pages without images

Best Practices

Do

  • Use 1200x630px images for optimal display
  • Keep text centered in the image (networks crop differently)
  • Use a different headline for Social vs SEO if audience differs
  • Force a scrape if you update the image

Don't

  • Use massive file sizes (keeps stats low), aim for <300KB
  • Rely on random scraped images
  • Ignore the default fallback image

Verification Checklist

  • View Source > Search "og:"
  • og:image is defined and accessible
  • Facebook Sharing Debugger shows the correct preview
  • LinkedIn Post Inspector shows the correct preview

Pro Tips

  • Add "twitter:card" metadata as well (usually "summary_large_image")
  • If the image doesn't update on potential shares, use the Facebook Debugger "Scrape Again" button

Common Issues & Fixes

Problem: Wrong image showing on Facebook
Solution: Facebook caches aggressively. You MUST use the Sharing Debugger tool to force a refresh.
Problem: Image is cropped weirdly
Solution: Ensure physical dimensions are 1200x630 (1.91:1 ratio). Square images often look bad in news feeds.
Problem: No image showing
Solution: Check if the image URL is https. Some platforms reject http images.