
Live Google, Twitter/X & LinkedIn social card generator
Preview your website on Google, Twitter/X, and LinkedIn. Generates HTML meta tags and Next.js Metadata.
When developers or readers share your article link on X (Twitter), LinkedIn, Discord, or Slack, how does it appear?
Does it generate a rich, high-resolution preview card with an eye-catching visual, engaging headline, and concise summary? Or does it display a barren, broken link with a generic domain fallback?
Research from Buffer and HubSpot indicates that links accompanied by rich Open Graph summary cards receive over 3.2x higher click-through rates (CTR) compared to plain text URLs.
In the Next.js App Router, the old patterns of injecting <Head> components from next/head are officially obsolete. In their place is a unified, strongly typed Metadata API that smoothly handles static definitions, asynchronous generateMetadata() data-fetching, canonical URL resolution, and dynamic edge-generated social graphics.
Want to see how your site looks on Google, Twitter, and LinkedIn before publishing? Test your URLs with our companion Open Graph & Meta Tag Previewer Tool.
generateMetadata()Next.js provides two primary ways to declare document metadata in your routes:
| Feature | Static metadata Object | Dynamic generateMetadata() Function |
|---|---|---|
| Use Case | Static pages (Home, About, Contact, Tools index) | Dynamic routes ([slug], [id], parameterized e-commerce or blog posts) |
| Data Fetching | Zero async overhead; defined directly as a constant object | Full async support; can query databases, CMS, or fetch APIs |
| Performance Caching | Computed once at build time during static generation | Automatically deduplicated with parent page data fetches via React cache() |
| Execution Environment | Pure server execution; 0 kB shipped to client bundle | Pure server execution; 0 kB shipped to client bundle |
<Head> to Next.js App Router MetadataHere is how legacy Next.js Pages Router metadata transforms into modern, type-safe App Router metadata:
Both Twitter and Facebook specify an aspect ratio of roughly 1.91:1. Creating your Open Graph images at 1200px width by 630px height ensures crisp rendering on high-DPI displays without awkward automatic cropping.
Social crawlers (like facebookexternalhit or Twitterbot) do not execute JavaScript and cannot resolve relative paths like /static/images/og.webp. Always prefix your image URLs with your full domain name: https://locionic.com/static/images/og.webp.
If your content is accessible under multiple URLs (e.g. /?utm_source=twitter or /en/blog/post), setting alternates: { canonical: '...' } instructs Google to concentrate all ranking authority on the primary canonical URL.
Why must Open Graph image URLs always be absolute paths ('https://...') rather than relative paths ('/og.png')?
Clean AI CLI logs, build cron expressions, decode JWTs, and calculate chmod permissions offline.

How Next.js 15 Partial Prerendering streams dynamic components inside static shells: Suspense architecture, TTFB drops, and edge caching.
Read more
Next.js 15 cache architecture explained: cacheLife, cacheTag, Server Action revalidation, and mastering stale-while-revalidate data flow.
Read more
Deep dive into Next.js 15 PPR: hybrid streaming wire format, React 19 Flight protocol, and eliminating hydration layout shifts.
Read more