og:image size

og:image size cheat sheet 2026

Ship 1200 by 630 pixels, close to 1.91:1, and keep the file under 600 KB. That is the open graph image size that meets the floors and caps Facebook, LinkedIn, WhatsApp, and iMessage actually publish. X does not publish a current size. This og image size page only states figures from the vendor docs linked below. A cell says "not published" when that doc is silent. Telegram is omitted: its public API describes link previews, and it does not publish an og:image pixel size, file cap, or format list.

Get an API key to receive a 1200 by 630 image from the API, or install MCP so an agent can call generate_og_image or compress_image. Or generate one now before you wire auth. Then check the live URL in the Open Graph debugger. Related guides: the OG image API comparison, the Next.js OG image guide, dynamic OG images for Astro, the WordPress plugin, how to change the OG image in WordPress, and the API docs.

Platform sizes

Platform Recommended Aspect ratio Minimum Max file size Formats Crop / safe area Meta tags
Facebook At least 1200 by 630 for high-resolution devices. Close to 1.91:1. 200 by 200. Use at least 600 by 315 for a larger link post. Smaller than that still shows, but much smaller. Must not exceed 8 MB. Not stated on the images page. Stay near 1.91:1 so Feed can show the full image without cropping. No safe-area inset is published. og:image. Set og:image:width and og:image:height so the crawler can render before it downloads the file.
X (Twitter) Not published. Not published. Not published. Not published. Not published. Not published. No current Cards markup reference on docs.x.com to cite. The old size page now redirects to the platform overview.
LinkedIn 1200 by 627 is the sharing-module minimum. Recommended ratio is 1.91:1. No separate larger size is published. 1.91:1. 1200 by 627. The same help page says images under 401 px wide display as a thumbnail. 5 MB for the sharing module. Not stated for the sharing module. JPG, PNG, and GIF are listed under single-image ads, a different spec. No safe area for link shares. A tip on the same page says square and vertical images might be cropped when ads are shared organically. og:title, og:image, og:description, og:url. Width and height are not in that list.
Slack Not published. Not published. Not published. Not published. Not published. Not published. Slackbot-LinkExpanding looks for oEmbed, Twitter Card tags, and Open Graph tags, then fetches an image the tags point at.
WhatsApp No single pixel size. Under 600 KB, at least 300 px wide, width/height of 4:1 or less. 4:1 or less (width divided by height). 300 px wide. Under 600 KB. Not stated. Not published. WhatsApp may relax the rules, and says not to rely on that. og:title, og:description, og:url, and og:image in the head. The image URL must be absolute. The head must sit inside the first 300 KB of HTML.
iMessage At least 900 px wide. No height is published. TN3156 calls this a guideline. Not published. Under 150 px wide may be ignored or shown as an icon. Icons should be square and at least 108 px. No per-image cap. The page itself is limited to 1 MB. Icons, images, and videos together are limited to 10 MB. Not stated for the preview image. The preview size changes by device. Avoid text in the image. No safe-area inset is published. og:image and og:title. Put the site name in og:site_name, not in the title. Also supply a favicon, apple-touch-icon, or link rel icon.
Discord Not published. The quick-start sample sets width 1200 and height 630. That sample is not a requirement. Not published. Not published. Not published. A link shows at most 4 images. .png, .gif, .jpg, .jpeg, .webp, and .avif. Not published. summary_large_image shows a large image under the text. With no layout tag, the image is small. Two or more og:image tags become a gallery. og:title or twitter:title, og:description or twitter:description, og:image or twitter:image, plus width, height, and og:image:type. twitter:card summary_large_image selects the large layout.

Sources: Meta Images in Link Shares, the Open Graph protocol at ogp.me, the X developer overview (the old large-image card URL redirects there), LinkedIn's make-your-website-shareable article, Slack's robots page and unfurl docs, WhatsApp link previews, Apple TN3156, and Discord link previews. Slack's robots page also says unfurl responses are cached for around 30 minutes. Discord says previews are cached for about 30 minutes. Those are cache notes, not image sizes.

Copy-paste tags, API, and MCP

og:image, og:image:width, and og:image:height are in Meta's images doc and on ogp.me. og:image:type, og:image:secure_url, and og:image:alt are protocol properties. twitter:card summary_large_image is the value Discord uses for a large image, and the value Apple names for social-post previews. WhatsApp's doc only requires og:title, og:description, og:url, and an absolute og:image. Put the head markup in the first HTML response. WhatsApp only reads tags inside the first 300 KB.

POST https://ogpilot.com/api/v1/images
Content-Type: application/json
Accept: application/json

{"token":"YOUR_JWT_TOKEN"}

Documented completed JSON includes width 1200 and height 630.
There is no width or height request field.
Required JWT claims: iss (verified domain), sub (API key prefix).
Optional: iat, template, title, description, path.

The template canvas is 1200 by 630, and the preview variant is a JPEG limited to that size. Sign the JWT on your server. The JavaScript SDK reads OG_PILOT_API_KEY and OG_PILOT_DOMAIN, then createImage returns the CDN URL you place in og:image and twitter:image.

Remote MCP URL: https://ogpilot.com/mcp
Transport: Streamable HTTP
Auth: OAuth 2.1 with PKCE

generate_og_image
{ "url": "https://example.com/pricing" }

compress_image
{ "image_url": "https://cdn.example.com/og.jpg", "width": 1200, "height": 630 }

generate_og_image takes a page url and an optional style. It returns image_url. The schema has no width or height field. The card is rendered on the 1200 by 630 template. compress_image is the tool that accepts width and height. Both default to 1200 and 630, format defaults to jpeg, and fit defaults to cover. Generation needs a signed-in account with an active plan. compress_image works on a guest connector session. A trial is not enough for generation. The tool returns plan_required and does not start a checkout.

How to choose an og:image size

  1. Prefer one 1200 by 630 image near 1.91:1 when a single file has to clear the published floors.
  2. Keep that file under 600 KB so it also clears WhatsApp's cap.
  3. Set an absolute https og:image, plus og:image:width and og:image:height.
  4. Add twitter:card summary_large_image when you want Discord's large-image layout.
  5. Generate the file with the API or MCP, then check the public URL in the Open Graph debugger.

What og:image size should I use? One 1200 by 630 file under 600 KB. What is the maximum og:image file size? Meta's cap is 8 MB, LinkedIn's sharing module is 5 MB, and WhatsApp's is 600 KB. Messages limits the page to 1 MB and associated resources to 10 MB. Slack, X, and Discord do not publish an image byte cap in the docs cited here. Does X publish an og:image size? Not in a current Cards reference. Does the OG Pilot API take a width and height? No. The documented JSON response includes width 1200 and height 630.