This skill generates Open Graph images aligned with your design system and configures meta tags to optimize social sharing.
npx playbooks add skill stevysmith/og-image-skill --skill og-image
This skill creates professional Open Graph images for social media sharing. It analyzes the existing codebase to match the project's design system, generates a dedicated OG image page, screenshots it, and configures all necessary meta tags.
Explore the project to understand:
package.json for Next.js, Vite, Astro, Remix, etc./og-image routetailwind.config.js/ts) for color palette:root definitions)/public, /assets, /src/assetspackage.json, landing page, or meta tagsCreate a dedicated route at /og-image (or equivalent for the framework):
Page Requirements:
[data-nextjs-dialog-overlay],
[data-nextjs-dialog],
nextjs-portal,
#__next-build-indicator {
display: none !important;
}
Content Structure:
Design Principles:
Use Playwright to capture the OG image:
http://localhost:3000/og-image or similar)og-image.pngPlaywright Commands:
browser_navigate: http://localhost:{port}/og-image
browser_resize: width=1200, height=630
browser_take_screenshot: og-image.png (then copy to /public)
Audit and update the project's meta tag configuration. For Next.js App Router, update layout.tsx. For other frameworks, update the appropriate location.
Required Meta Tags:
// Open Graph
openGraph: {
title: "Product Name - Short Description",
description: "Compelling description for social sharing",
url: "https://yourdomain.com",
siteName: "Product Name",
locale: "en_US",
type: "website",
images: [{
url: "/og-image.png", // or absolute URL
width: 1200,
height: 630,
alt: "Descriptive alt text for accessibility",
type: "image/png",
}],
},
// Twitter/X
twitter: {
card: "summary_large_image",
title: "Product Name - Short Description",
description: "Compelling description for Twitter",
creator: "@handle", // if provided
images: [{
url: "/og-image.png",
width: 1200,
height: 630,
alt: "Descriptive alt text",
}],
},
// Additional
other: {
"theme-color": "#000000", // match brand color
"msapplication-TileColor": "#000000",
},
appleWebApp: {
title: "Product Name",
statusBarStyle: "black-translucent",
capable: true,
},
Ensure metadataBase is set for relative URLs to resolve correctly:
metadataBase: new URL("https://yourdomain.com"),
Only ask the user if these cannot be determined from the codebase:
Next.js App Router:
/app/og-image/page.tsx/app/layout.tsx'use client' directive for the OG pageNext.js Pages Router:
/pages/og-image.tsx_app.tsx or use next-seoVite/React:
index.html meta tags or use react-helmetAstro:
/src/pages/og-image.astroBefore completing, verify:
Weekly roundup of top Claude Code skills, MCP servers, and AI coding tips.