When someone shares a link, the platform tries to build a preview card — a title, a description, an image. Left to guess, it picks whatever it can find, often badly. Open Graph tags let you specify exactly what appears.
<head>
<meta property="og:title" content="How to Choose a Laptop for Students">
<meta property="og:description" content="What specifications actually matter, what to skip, and how much you need to spend.">
<meta property="og:image" content="https://example.com/images/laptop-guide-og.jpg">
<meta property="og:url" content="https://example.com/guides/laptop-buying-guide">
<meta property="og:type" content="article">
<meta property="og:site_name" content="TechShop">
</head>Open Graph originated at Facebook but is now read by most platforms that render link previews — messaging apps, Slack, LinkedIn, and others. Adding it once covers most places a link can be shared.
A small number of extra tags control the card format on X specifically. If they are absent, the platform falls back to the Open Graph tags, so these are optional refinement rather than a requirement:
<meta name="twitter:card" content="summary_large_image">In a feed of text, the preview image is what stops the scroll. A few practical points:
These tags have no effect on search rankings. They exist entirely to control how a link looks when shared. They earn their place through clicks from social and messaging, which is a different channel from search — but the same page benefits from both.
Platforms cache previews aggressively. If you share a link, then fix the tags, the old preview will usually persist — sometimes for a long time. Most major platforms provide a debugging tool that fetches the page fresh and refreshes their cached copy.
The practical implication: get the tags right before a link is widely shared, rather than fixing them after. Recovering from a bad cached preview is more work than setting it correctly the first time.
For most pages, Open Graph tags can be generated from data you already have — the page title, the meta description, and a representative image. Hand-writing them per page is only worth it for pages you expect to be shared heavily. Having a reasonable site-wide default image, so that no link ever previews with nothing at all, matters more than perfecting each one.