OG Images for Blog Posts
An OG image for blog posts is the 1200×630 social preview image shown when someone shares your article on X, LinkedIn, Facebook, Slack, or WhatsApp. FastOG generates it dynamically on demand from your post title, excerpt, and author — no design work, no uploading, no subscriptions, credit-based, no login to start.
Why each blog post needs its own OG image
A link shared without a card, or with a stale generic one, blends into every other post. A per-post card with the actual title and a clean layout gets more shares and more clicks. The cost of generating one per post by hand is why most blogs settle for a single default image — that is exactly the problem FastOG removes.
How to get a dynamic OG image for a blog post
You sign a URL at page-render time with template=blog, the post title, an excerpt, and the author. The social crawler fetches it, FastOG renders the PNG once, and Cloudflare caches it so every later share is instant and free.
// Next.js App Router — app/blog/[slug]/page.tsx
export async function generateMetadata({ params }) {
const post = await getPost(params.slug);
return {
title: post.title,
openGraph: {
images: [generateOgImageUrl({
template: "blog",
title: post.title,
subtitle: post.excerpt,
author: post.author.name,
})],
},
};
}
Use
template=blogfor a dedicated blog card with author + headline, ordefaultfor a cleaner title-only layout. All templates render at 1200×630.
Which template fits your blog
| If your blog… | Use template | Bonus |
|---|---|---|
| Shows author + excerpt | blog |
author line included |
| Is mostly title + tagline | default |
minimal, brand-focused |
| Uses a photo or cover art | editorial / image-right |
photo-led layout |
| Publishes launch / product posts | launch |
version + domain fields |
FAQ
How much does FastOG cost for blog posts?
One credit per unique image; identical URLs are edge-cached forever and cost nothing more. First 100 credits are free to try.
Do I need to regenerate an image when I edit a post?
Only if the title, excerpt, or author changes — the URL depends on the content, so a content change yields a new URL and a new render (1 credit). An unchanged URL stays cached.
Can I use FastOG with my existing blog framework?
Yes. Drop-in signers exist for Next.js, React, SvelteKit, Vue/Nuxt, Astro, Express, Vanilla Node.js, JavaScript, PHP/Laravel, Python, and Ruby/Rails. See the SDK page.
Related
Try it free — no signup required
Preview and test dynamic OG images in seconds.
Open the Free OG Image Tester