# A letter to a founder about link previews

> What Facebook, LinkedIn, WhatsApp and Slack say they do with your og:image tags, how to check a page before launch, and one card per page made from HTML.

Letter by Serghei Pogor, founder of CurlShot (https://curlshot.com/about/serghei-pogor). Published 18 November 2026. Page for people: https://curlshot.com/blog/link-previews-letter-to-a-founder

A link preview is built by a robot that reads the og: meta tags in your page's HTML: title, description, url and image. Each platform asks for different limits (Meta 8 MB, LinkedIn 5 MB, WhatsApp under 600 KB), caches the result, and says little about a missing image. Check a page by loading it with each crawler's user agent, and make a separate 1200 by 630 card for every page. CurlShot renders that card from HTML with one request.

## Key facts

- Four tags carry a preview: og:title, og:description, og:url and og:image. LinkedIn lists them as tags that must exist, and WhatsApp wants the first three in the head and the image as a full address.
- The numbers differ per platform: Meta allows 8 MB and 200 x 200 px at the least, LinkedIn 5 MB and asks for 1200 x 627, WhatsApp wants under 600 KB and 300 px wide. One 1200 x 630 image under 600 KB meets all three.
- A changed image needs a new file name: Meta caches by address, LinkedIn keeps a cached preview until Post Inspector refreshes it, and Slack caches for about 30 minutes.
- A page can answer a crawler differently from a browser. Load it with each crawler's user agent, and read the tags in what comes back.
- A checker run on ten stand-in pages reported each planted fault (no image, a relative address, 300 px wide, 2 MB, a 404, tags after 480 KB, crawlers blocked, one image on two pages) and passed the clean page.
- With the docs template, a title of 115 characters or more pushes text into the margins of the card, and at 179 the first and last lines are cut off. A three-line clamp keeps every length inside. CurlShot makes the card from HTML.

## The letter in short

Dear founder,

Every app that shows a preview of your link sends a robot to your page, and the robot reads the meta tags in the HTML. This letter covers what four of those apps say they want, how to look at your page the way they do, and how to make one preview image per page from HTML.

## What each app says about the cases that go wrong

Each row below is a fault a page can have. For each platform the table says whether its own page states the rule (read on 2026-11-12). "No" means the page leaves the case out, and nothing is guessed. Numbers in brackets point at the sources list.

### No og:image at all

The page has a title and a description, and no picture tag.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | No | Not stated. The page names og:image as the tag that sets the picture and says nothing about a page without it. [2] |
| LinkedIn | Yes | og:image is one of the tags that "must exist": title, image, description and url. [5] |
| WhatsApp | Yes | A page that does not meet the requirements "may risk the link to be not previewed". WhatsApp may try other markup and a small preview, but the page says not to rely on that. [7] |
| Slack | No | Not stated. Slack looks for oEmbed, Twitter Card and Open Graph tags and draws "some micro-approximation of the content". [8][9] |

### The image address is not a full address

og:image says /og.png instead of the whole address.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | No | Not stated as an error. The examples use full addresses, and og:image:secure_url is described as an https:// URL. [2] |
| LinkedIn | No | Not stated as an error. Its own example is protocol-relative: //media.example.com/1234567.jpg. [5] |
| WhatsApp | Yes | og:image is "an absolute URL for an image used as the thumbnail". [7] |
| Slack | No | Not stated. [8] |

### The image is too small

A 300 px wide logo used as the share picture.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | Yes | 200 x 200 px is the smallest allowed. Under 600 x 315 px it still shows, but "much smaller". At least 1200 x 630 px for high resolution screens. [2] |
| LinkedIn | Yes | The sharing module asks for at least 1200 x 627 px. "Images less than 401 pixels wide display as a thumbnail image." [5] |
| WhatsApp | Yes | 300 px or more in width, and 4:1 width to height or less. [7] |
| Slack | No | No size is stated. [8] |

### The image file is too heavy

A 1200 x 630 picture that is 2 MB because it is a PNG of a photo.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | Yes | The file "must not exceed 8 MB". [2] |
| LinkedIn | Yes | Max file size: 5 MB. [5] |
| WhatsApp | Yes | "This image should be under 600KB in size." [7] |
| Slack | No | No limit is stated. Slack fetches the image file "to check validity". [8] |

### The robot gets a different answer than a browser

A firewall, a login wall or a missing file answers the crawler with an error.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | Yes | The guide tells you to load the page with the crawler's user agent, because a page can answer it differently from a browser. The crawler only accepts gzip and deflate encodings. [3][2] |
| LinkedIn | Yes | If the image meets the rules and still does not show, "your website may be blocking us from pulling the image or the image may be located on a protected directory". [5] |
| WhatsApp | Yes | The crawler sends a GET with the user agent WhatsApp/2.x.x.x. Owners can recognise it and send it their own markup and images. [7] |
| Slack | Yes | Slackbot-LinkExpanding fetches the page with HTTP Range headers, then fetches the image file to check it is valid. [8] |

### You changed the image and the old one still shows

The file is new, the preview is not.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | Yes | Images are cached by URL and "won't be updated unless the URL changes". Re-scrape with the Sharing Debugger or the Graph API. [2][3] |
| LinkedIn | Yes | The preview may be cached. Post Inspector refreshes it, for new posts only: existing posts keep the old preview. [6] |
| WhatsApp | No | Not stated. [7] |
| Slack | Yes | Responses are "cached globally across the service for around 30 minutes". [8] |

### The tags sit too far down the page

A huge inline style or script comes before the meta tags.

| Platform | Does its page say? | What it says |
| --- | --- | --- |
| Facebook (Meta) | No | Not stated. [3] |
| LinkedIn | No | Not stated. [5] |
| WhatsApp | Yes | The head with the tags "must appear within the first 300KB of the HTML". [7] |
| Slack | No | No limit is stated, but the robot "fetches as little of the page as it can", so keep the tags early. [8] |

The X card pages we tried (the older developer.x.com cards guides) now redirect to the developer overview, so there is no X page to cite for any row above. X's own docs site sets og:image and twitter:image to one file and twitter:card to summary_large_image. [10]

## How to look at a page the way the robots do

Three checks, from fastest to most complete.

1. Run curl with a crawler's user agent and read the tags it prints. If no og: lines come back, the robot sees none:

```bash
curl -sA 'WhatsApp/2.22.20.72 A' https://your-app.example/pricing | head -c 307200 | grep -io '<meta[^>]*og:[^>]*>'
```

2. Use the platforms' own tools: the Sharing Debugger shows the tags Meta's crawler scraped, with errors and warnings, and starts a new scrape [3]. LinkedIn's Post Inspector refreshes a cached preview [6].
3. Run the checker below. It fetches the page with a browser and with three crawler user agents, reads the tags, fetches the image and compares both with the numbers in the table above.

```js
// ogcheck.mjs: node ogcheck.mjs <page-url> [<page-url> ...]
// Fetches each page the way four crawlers do, reads its Open Graph tags,
// fetches the og:image and compares both with what the platform docs ask for.
const AGENTS = {
  browser: 'Mozilla/5.0',
  facebook: 'facebookexternalhit/1.1 (+http://www.facebook.com/externalhit_uatext.php)',
  whatsapp: 'WhatsApp/2.22.20.72 A',
  slack: 'Slackbot-LinkExpanding 1.0 (+https://api.slack.com/robots)',
}
const KB = 1024

function size(bytes) {
  // PNG: width and height sit at bytes 16-23. JPEG: scan to a start-of-frame marker.
  if (bytes[0] === 0x89 && bytes[1] === 0x50) return { w: bytes.readUInt32BE(16), h: bytes.readUInt32BE(20) }
  if (bytes[0] === 0xff && bytes[1] === 0xd8) {
    for (let i = 2; i < bytes.length - 9; ) {
      if (bytes[i] !== 0xff) { i++; continue }
      const m = bytes[i + 1]
      if (m >= 0xc0 && m <= 0xcf && m !== 0xc4 && m !== 0xc8 && m !== 0xcc) return { h: bytes.readUInt16BE(i + 5), w: bytes.readUInt16BE(i + 7) }
      i += 2 + bytes.readUInt16BE(i + 2)
    }
  }
  return null
}

function tags(html) {
  const found = {}
  for (const tag of html.match(/<meta\s[^>]*>/gi) ?? []) {
    const key = /(?:property|name)\s*=\s*["']([^"']+)["']/i.exec(tag)?.[1]
    const value = /content\s*=\s*["']([^"']*)["']/i.exec(tag)?.[1]
    if (key && value !== undefined && !(key in found)) found[key] = value
  }
  return found
}

async function get(url, agent) {
  try {
    const res = await fetch(url, { headers: { 'user-agent': AGENTS[agent], accept: '*/*' }, redirect: 'follow' })
    return { status: res.status, type: res.headers.get('content-type') ?? '', body: Buffer.from(await res.arrayBuffer()) }
  } catch (error) {
    return { status: 0, type: '', body: Buffer.alloc(0), error: error.cause?.code ?? error.message }
  }
}

const seenImages = new Map()

for (const url of process.argv.slice(2)) {
  const out = []
  const say = (level, text) => out.push(level + ' ' + text)
  const page = await get(url, 'browser')
  if (page.status !== 200) { say('FAIL', 'page answered ' + (page.status || page.error) + ' to a browser'); console.log(url + '\n' + out.join('\n') + '\n'); continue }

  for (const agent of ['facebook', 'whatsapp', 'slack']) {
    const res = await get(url, agent)
    if (res.status !== 200) say('FAIL', agent + ' crawler gets ' + (res.status || res.error) + ', a browser gets 200')
  }

  const html = page.body.toString('utf8')
  const t = tags(html)
  for (const name of ['og:title', 'og:description', 'og:url', 'og:image']) if (!t[name]) say('FAIL', 'no ' + name)
  const at = page.body.indexOf('og:image')
  if (at > 300 * KB) say('FAIL', 'og:image starts at byte ' + at + ', past the first 300 KB WhatsApp reads')
  if (!t['twitter:card']) say('WARN', 'no twitter:card')
  if (t['og:image'] && !t['og:image:width']) say('WARN', 'no og:image:width / og:image:height (Meta: needed to render on the first share)')

  if (t['og:image']) {
    const absolute = /^https?:\/\//i.test(t['og:image'])
    if (!absolute) say('FAIL', 'og:image is "' + t['og:image'] + '", not an absolute URL (WhatsApp asks for one)')
    const imageUrl = new URL(t['og:image'], url).href
    const img = await get(imageUrl, 'browser')
    if (img.status !== 200) {
      say('FAIL', 'image answered ' + (img.status || img.error))
    } else {
      const dims = size(img.body)
      const kb = Math.round(img.body.length / KB)
      const before = out.length
      if (!['image/png', 'image/jpeg', 'image/gif'].includes(img.type.split(';')[0])) say('WARN', 'image type ' + img.type + ' is not one of the three Meta lists')
      if (img.body.length > 600 * KB) say('FAIL', 'image is ' + kb + ' KB, WhatsApp asks for under 600 KB')
      if (!dims) say('WARN', 'could not read the image size')
      else {
        const { w, h } = dims
        if (w < 200 || h < 200) say('FAIL', w + 'x' + h + ' is under the 200x200 minimum Meta allows')
        else if (w < 600 || h < 315) say('FAIL', w + 'x' + h + ' is under 600x315: Meta shows it much smaller')
        if (w < 401) say('FAIL', 'only ' + w + ' px wide: LinkedIn shows images under 401 px as a thumbnail')
        else if (w < 1200 || h < 627) say('WARN', w + 'x' + h + ' is under the 1200x627 LinkedIn lists as its minimum')
        if (w < 300) say('FAIL', 'under 300 px wide, which WhatsApp asks for')
        if (w / h > 4) say('FAIL', 'wider than 4:1, the WhatsApp limit')
        if (out.length === before) say('PASS', 'image ' + w + 'x' + h + ', ' + kb + ' KB, ' + img.type)
      }
      const other = seenImages.get(imageUrl)
      if (other) say('WARN', 'same image as ' + other + ': every page shares one preview')
      else seenImages.set(imageUrl, url)
    }
  }
  if (!out.some((line) => line.startsWith('FAIL'))) say('PASS', 'no failing check')
  console.log(url + '\n' + out.join('\n') + '\n')
}
```

## The checker on ten stand-in pages

Run on 2026-11-12 against a local server that plays each fault once. Each page was checked on its own, except the last two, which share one run so the duplicate-image check can fire.

| Page | What it does | The checker printed |
| --- | --- | --- |
| /good | Title, description, url, 1200 x 630 image, size tags, twitter:card | PASS image 1200x630, 4 KB, image/png / PASS no failing check |
| /no-image | Everything except og:image | FAIL no og:image |
| /relative | og:image is /img/good.png | FAIL og:image is "/img/good.png", not an absolute URL (WhatsApp asks for one) / PASS image 1200x630, 4 KB, image/png |
| /tiny | The image is 300 x 157 | FAIL 300x157 is under the 200x200 minimum Meta allows / FAIL only 300 px wide: LinkedIn shows images under 401 px as a thumbnail |
| /heavy | A 1200 x 630 PNG of random noise, 2216 KB | FAIL image is 2216 KB, WhatsApp asks for under 600 KB |
| /missing-file | og:image points at a file that answers 404 | FAIL image answered 404 |
| /late | About 480 KB of inline style before the meta tags | FAIL og:image starts at byte 480260, past the first 300 KB WhatsApp reads / PASS image 1200x630, 4 KB, image/png |
| /blocks-bots | Answers 403 to the WhatsApp, Facebook and Slack user agents | FAIL facebook crawler gets 403, a browser gets 200 / FAIL whatsapp crawler gets 403, a browser gets 200 / FAIL slack crawler gets 403, a browser gets 200 / PASS image 1200x630, 4 KB, image/png |
| /shared-a | A clean page with its own image | PASS image 1200x630, 4 KB, image/png / PASS no failing check |
| /shared-b | A second clean page with the same image as /shared-a | PASS image 1200x630, 4 KB, image/png / WARN same image as /shared-a: every page shares one preview / PASS no failing check |

The checker applies the numbers from the platform pages. It cannot tell you what an app draws, and the stand-in server is not one of the apps.

## Why a fix does not show

Meta caches an image by its address, so a replaced file keeps the old preview until the address changes [2]. LinkedIn may show a cached preview until Post Inspector refreshes it, and only for new posts [6]. Slack caches what its robot fetched for about 30 minutes [8]. Give every changed image a new file name, and keep the old file: Meta warns that earlier shares may still point at it [2].

## One card per page, made from HTML

A picture shared by every page makes every link look like the home page. Design one card as HTML, fill in the title for each page, render it at 1200 by 630 pixels and save the file when the page is published. The full recipe is in [CurlShot docs: Open Graph images](https://curlshot.com/docs/guides/open-graph-images). The request:

```bash
jq -n --rawfile html card.html \
  '{html: $html, viewport_width: 1200, viewport_height: 630, format: "png"}' \
| curl -X POST "https://curlshot.com/api/v1/screenshot" \
    -H "X-Access-Key: YOUR_ACCESS_KEY" \
    -H "Content-Type: application/json" \
    -d @- \
    --output og-card.png
```

Save the bytes under a name that changes with the content, and serve the file from your own site. Do not point og:image at the API: a POST cannot be written as a link, and stored files expire.

```js
import { createHash } from 'node:crypto'
import { mkdir, writeFile } from 'node:fs/promises'

// renderCard(post) sends the card HTML and returns the PNG bytes.
export async function saveCard(post) {
  const image = await renderCard(post)
  const hash = createHash('sha256').update(post.title + post.author).digest('hex').slice(0, 6)
  const path = 'og/' + post.slug + '-' + hash + '.png'

  await mkdir('public/og', { recursive: true })
  await writeFile('public/' + path, image)
  return path // store this with the post, and put it in og:image
}
```

The tags for the page:

```html
<meta property="og:title" content="How we cut our build time in half">
<meta property="og:description" content="What we changed, and what it saved.">
<meta property="og:url" content="https://your-app.example/blog/build-time">
<meta property="og:image" content="https://your-app.example/og/build-time-3f9a1c.png">
<meta property="og:image:width" content="1200">
<meta property="og:image:height" content="630">
<meta property="og:image:alt" content="How we cut our build time in half">
<meta name="twitter:card" content="summary_large_image">
```

### How long a title can be

The card template of the docs guide has a 72 px title in a box 1040 px wide. Chromium laid it out with 12 title lengths cut from one sentence. The last column adds the three-line clamp.

| Title characters | Lines | Text block top, plain (px) | Text block bottom, plain (px) | Text bottom, clamped (px) |
| --- | --- | --- | --- | --- |
| 20 | 1 | 204 | 426 | 426 |
| 36 | 2 | 164 | 466 | 466 |
| 59 | 3 | 125 | 505 | 505 |
| 78 | 3 | 125 | 505 | 505 |
| 98 | 4 | 85 | 545 | 505 |
| 108 | 4 | 85 | 545 | 505 |
| 115 | 5 | 46 | 584 (in the padding) | 505 |
| 140 | 6 | 6 | 624 (in the padding) | 505 |
| 155 | 6 | 6 | 624 (in the padding) | 505 |
| 179 | 7 | -34 | 664 (cut off) | 505 |
| 199 | 8 | -73 | 703 (cut off) | 505 |
| 217 | 8 | -73 | 703 (cut off) | 505 |

The template centres its text in a box with 80 px of padding, so a long title grows both ways. The block should stay between 80 px and 550 px; the card runs from 0 to 630 px. A word of 45 letters (55 characters with the next word) with no place to break made the page 1823 px wide in the plain template and 1200 px with the clamp. The line that fixes both:

```css
h1 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
```

## Six lines to run before launch

1. Run the checker on five real pages: home, pricing, a blog post, a docs page, a signup page. Fix every FAIL.
2. Look at the WARN lines. Two pages with the same image are the usual one.
3. Run the curl line with the WhatsApp user agent on one page. If no og: tags print, the robot sees none.
4. Paste one address into the Sharing Debugger and into Post Inspector, and read what they report.
5. Post one link in a private Slack channel. Check it again after 30 minutes if you changed anything.
6. Give every changed image a new file name. Never overwrite one that was shared.

## What was not checked

No app was sent a link in this run, so nothing here says what any app draws; the table only says what each platform's page states. LinkedIn's pages were last updated three years ago, by their own labels. The stand-in pages are one server on one machine. The card test was one template in one browser.

Yours, CurlShot

## Questions

### What does a link preview show when og:image is missing?

It depends on the app, and the platforms' own pages say little. LinkedIn lists og:image among the tags that must exist. WhatsApp says a link that misses the requirements may not be previewed, and that it may fall back to a small preview, which it says not to rely on. The Meta and Slack pages do not say. Read on 2026-11-12.

### How do I check what Facebook, LinkedIn, WhatsApp and Slack see on my page?

Load the page with curl and each crawler's user agent, then read the og: tags in the answer. Add the Sharing Debugger for Meta, Post Inspector for LinkedIn, and a test post in a private Slack channel. A short checker script can also compare the tags and the image with each platform's numbers, as the one in this letter does.

### Why does my link preview still show the old image?

The preview is cached. Meta caches an image by its address, LinkedIn keeps a cached preview until Post Inspector refreshes it, and Slack caches for about 30 minutes. Publish the new image under a new file name, then re-scrape or refresh.

### What size should an og:image be?

Use 1200 by 630 pixels, as a PNG or JPEG under 600 KB. That meets Meta's advice for high resolution screens, LinkedIn's 1200 by 627 minimum and WhatsApp's 600 KB and 300 px limits. The sizes of other platforms are in the size chart article linked below.

### Can every page of my site have its own og:image?

Yes. Design the card as HTML, put each page's title in it, render it at 1200 by 630 pixels, save the file under a new name per title, and point that page's og:image at it. CurlShot renders the card from HTML with one request; a repeat of the same request is served from the cache and not counted.

## Sources

1. ogp.me, "The Open Graph protocol": https://ogp.me/ (checked 12 November 2026)
2. Meta for Developers, "Images in Link Shares": https://developers.facebook.com/docs/sharing/webmasters/images/ (checked 12 November 2026)
3. Meta for Developers, "A Guide to Sharing for Webmasters": https://developers.facebook.com/docs/sharing/webmasters/ (checked 12 November 2026)
4. Meta for Developers, "Sharing best practices": https://developers.facebook.com/docs/sharing/best-practices/ (checked 12 November 2026)
5. LinkedIn Help, "Make your website shareable on LinkedIn": https://www.linkedin.com/help/linkedin/answer/a521928 (checked 12 November 2026)
6. LinkedIn Help, "Use Post Inspector to refresh URL": https://www.linkedin.com/help/linkedin/answer/a6233775 (checked 12 November 2026)
7. WhatsApp Business Platform, Meta for Developers, "Link Previews": https://developers.facebook.com/docs/whatsapp/link-previews/ (checked 12 November 2026)
8. Slack, "Slack Robots": https://api.slack.com/robots (checked 12 November 2026)
9. Slack Developer Docs, "Unfurling links in messages": https://docs.slack.dev/messaging/unfurling-links-in-messages/ (checked 12 November 2026)
10. X, "X Developer Platform overview (the page the old cards guides now redirect to)": https://docs.x.com/overview (checked 12 November 2026)

## Go deeper

- [Open Graph image generator](https://curlshot.com/tools/open-graph-image-generator)
- [HTML to image](https://curlshot.com/tools/html-to-image)
- [Guide: Open Graph images from HTML](https://curlshot.com/docs/guides/open-graph-images)
- [Pricing](https://curlshot.com/pricing)

## Read next

- [Social preview image sizes: the OG cheat sheet](https://curlshot.com/blog/social-preview-image-sizes.md): Open Graph image sizes for Facebook, LinkedIn, WhatsApp, iMessage, Discord, Slack and Google Discover, drawn to scale, with the tags and the fixes.
- [HTML to image: six templates you can copy](https://curlshot.com/blog/html-to-image-templates.md): Six copyable HTML and CSS templates: social card, certificate, receipt, quote card, ticket and stat card, with sizes and the rules that make them render right.
