sodcalculator

10 Tech How-To

Check Open Graph Image Before WhatsApp Share

Guide 10-16588 · Updated · Step by step

Before you paste a link into WhatsApp, the app pulls a preview from the site’s Open Graph (OG) tags. If that image is missing, wrong, or outdated, your message looks broken or misleading. This guide shows you how to inspect a page’s OG image in seconds, so you can decide whether to share it as-is or grab a better link.

What You’ll Need

  • A web browser (Chrome, Firefox, Edge, or Safari) on any device.
  • The URL of the page you want to check.
  • Optional: a free online OG checker tool (like the one at opengraph.xyz or Metatags.io) if you want a visual preview without digging into code.

Step-by-Step

  1. Open the page in your browser. Go to the URL you plan to share. Make sure you’re on the exact page, not a redirect or a mobile subdomain (like m.example.com), because the OG tags can differ.
  2. Open the page source. Right-click anywhere on the page (not on an image) and select “View Page Source” (or “View Source” in Safari). This opens a new tab with the raw HTML.
  3. Find the OG tags. Press Ctrl+F (Windows) or Cmd+F (Mac) to open the search box. Type og:image and press Enter. You’ll see one or more lines like this:
    <meta property="og:image" content="https://example.com/image.jpg">
  4. Copy the image URL. Select the full URL inside the content attribute and copy it. If there are multiple og:image tags, the first one is usually the primary image.
  5. Open the image URL in a new tab. Paste the copied URL into your browser’s address bar and press Enter. If the image loads, it exists and is accessible. If you see a 404 error or a blank page, the image is broken.
  6. Check the image dimensions (optional but important). WhatsApp recommends images at least 300×200 pixels, but larger images (like 1200×630) look better and are less likely to be cropped. To check dimensions: right-click the image in the new tab and select “Inspect” (or “Inspect Element”). In the developer tools that open, find the “Properties” tab or look for the naturalWidth and naturalHeight values. Alternatively, download the image and check its properties on your computer.
  7. Verify the URL is public. The image URL must be publicly accessible—not behind a login, not on a localhost, and not a relative path (like /images/og.jpg). It must be an absolute URL starting with https://.
  8. Test with WhatsApp’s own preview (optional). If you want to be 100% sure, paste the link into a WhatsApp chat with yourself (using the “Message Yourself” feature) and see what preview appears. If it’s wrong, WhatsApp may have cached an old version—see Troubleshooting below.

Common Mistakes

  • Looking at the wrong URL: If the page redirects (e.g., from example.com to www.example.com), the OG tags on the final URL are what matter. Always check the final URL after all redirects.
  • Copying the wrong attribute: Make sure you copy the content attribute, not the property or name.
  • Ignoring multiple og:image tags: Some sites specify different images for different devices. The first tag is usually the default, but WhatsApp may pick a later one. Check all of them.
  • Forgetting about caching: WhatsApp caches previews aggressively. Even if the site owner fixes the image, WhatsApp may still show the old one for days or weeks.
  • Assuming a relative URL works: If the content attribute is /images/og.jpg, that’s not a complete URL. WhatsApp can’t resolve it. It must be a full URL like https://example.com/images/og.jpg.

Tips

  • Use an OG checker tool like opengraph.xyz or Metatags.io—they show you exactly what WhatsApp will see, including title, description, and image, without touching code.
  • Check the image file size: Large images (over 5MB) may fail to load in WhatsApp. If the image is huge, look for a smaller version or use a compression tool.
  • Look for a fallback: Some sites include a og:image:width and og:image:height tag. If those are missing, WhatsApp may still work, but providing them helps.
  • Test with a private browsing window: This avoids any cached versions in your browser, giving you the freshest source.
  • If the image is missing entirely, check if the site has a twitter:image tag—WhatsApp may fall back to it in some cases, but it’s not guaranteed.

Troubleshooting

The image loads in my browser, but WhatsApp shows a different one. This is almost always caching. WhatsApp stores previews for a long time. To force a refresh, you can append a query string to the URL (e.g., ?v=2) and share that. This creates a new URL that WhatsApp hasn’t seen, so it will fetch fresh OG tags.

I don’t see any og:image tag in the source. The site may not have implemented Open Graph tags. In that case, WhatsApp will try to guess an image from the page content, which often results in a random or broken preview. Your only option is to contact the site owner or choose a different link.

The image URL returns a 404 error. The image file has been moved or deleted. Check if there’s a different og:image tag, or try removing the last part of the URL path to see if the image is in a different folder. If not, the site is broken—share something else.

The image is too small or gets cropped badly. WhatsApp crops images to a 1.91:1 aspect ratio (like 1200×630). If your image is square or portrait, it will be cropped. You can’t fix this from your end; you’d need to use a different link or ask the site owner to update the OG image.

WhatsApp shows no preview at all. The page might be blocking bots, or the og:image URL might be blocked by hotlink protection. Try opening the image URL in an incognito window—if it still loads, it’s likely a bot-blocking issue. In that case, you can’t force WhatsApp to show a preview.

Frequently Asked Questions

Q: Can I change the OG image of a page I don’t own?
A: No. The OG tags are set by the site owner. You can only change them if you have access to the site’s code or CMS.

Q: Why does WhatsApp show a different image than Facebook?
A: Facebook and WhatsApp use different caching systems and may have slightly different rules for which image to pick. Also, Facebook lets you manually choose an image when sharing, while WhatsApp doesn’t.

Q: Does the OG image need to be HTTPS?
A: Yes, WhatsApp requires a secure HTTPS URL. If the image is served over HTTP, it may be blocked.

Q: How long does WhatsApp cache a preview?
A: There’s no official number, but it can be weeks or even months. Using a query string trick is the fastest way to force a refresh.

Q: Can I use a GIF as an OG image?
A: Technically yes, but WhatsApp will only show a static frame. It’s better to use a JPEG or PNG.

Q: What if the page has no OG tags at all?
A: WhatsApp will try to extract a thumbnail from the page’s content. This often fails or picks a random image. To guarantee a good preview, the site needs proper OG tags.

Related

General steps for current mainstream versions; menus can differ by device and version. See the disclaimer or report an error.

More in this bed

The whole Tech How-To bed →