og-image
Skill4 starsChanged 28 days agoMITView on GitHub
Generate an Open Graph / social share image (og:image, Twitter card) for the current project — a short title pitch over the product's real interface, built in the project's own stack from its real layout, components, tokens and copy, captured at 2x as a PNG and wired into the page meta tags. Use when asked for an OG image, social preview, share card, link preview image, or twitter:image.
7 other projects use a version of this.
Adopted by
Most recently taken up by
- exbald/skillstheir own version, first seen Nov 22, 2026
- posts-design/mcptheir own version, first seen Nov 22, 2026
- ImBIOS/skillstheir own version, first seen Nov 8, 2026
- HenryQW/skillstheir own version, first seen Jul 15, 2026
- Yahiasherif002/claude-skillstheir own version, first seen Jun 26, 2026
- MohamedAbdallah-14/prompt-to-assettheir own version, first seen May 6, 2026
Other versions7 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 7
- posts-design/mcp★ 77same name
- MohamedAbdallah-14/prompt-to-asset★ 18same name
- html2png/skills★ 10same name
- exbald/skills★ 1same name
- HenryQW/skills★ 1same name
- ImBIOS/skills★ 1same name
- Yahiasherif002/claude-skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository15 other files it gives its agents.
- article-imageSkill
- bento-featuresSkill
- deslopify-uiSkill
- landing-pageSkill
- low-res-mockupSkill
- narrated-feature-videoSkill
- og-image-animatedSkill
- og-image-liveSkill
- product-demoSkill
- pulse-repo-statsSkill
- saas-dashboardSkill
- saas-logoSkill
- website-screenshot-reelSkill
- website-scrollSkill
- write-changelogSkill
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 3 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 7 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 33
Read the homepage/landing component and README for the pitch, product name and sample content.
- Very specific: line 36
Check what's already there: an existing OG route/image, og:image meta in the root or page head, WEB_URL/site URL config.
- Distinctive: line 54
Start the dev server (or reuse one), then:
- Very specific: line 66
Port collisions: check the port is really serving this app (lsof -iTCP:<port> -sTCP:LISTEN, and look at the page title).
- Very specific: line 68
Don't hide overlays with broad :has() / body > div rules.
- Distinctive: line 75
No devtools badges, cursors, toasts, loading skeletons, or half-played animations.
- Very specific: line 88
Verify the tags appear in the served HTML (curl -s <page> | grep og:image) and the PNG URL returns 200 image/png.
“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
OG image
Every file this skill uses ships in its own folder, next to this SKILL.md, and paths here are relative to that folder. It needs nothing from other skills or other folders, so don't go looking for them. Unless the user names another place, save everything it makes in out/og-image/ under the current project.
A share card sells the product in the half second someone scrolls past a link. The formula: brand mark, one short title, and the real product underneath, cropped by the bottom edge. Nothing else.
Reference style (see references/):
control-panel.png— brand mark centered on top, a very large one-line title, then the app window (sidebar, header, list) starting at about a third of the height, bleeding off the bottom, with one floating detail panel on the right.pulse.png— same composition built from Pulse's real layout: sidebar with project icons, search header, project page with tabs, feed rows and the activity rail.
Rules
- Real product, never made up. Show the app as it ships today. Only use screens, tabs, labels, statuses and features that exist in the code. No invented metrics, charts or features, even if the landing page copy talks about them. If a marketing demo on the site shows something the app doesn't have, don't copy that demo.
- Messaging comes from the current site. Take the pitch and the sample content from the live homepage (its hero, its demo data) unless the user gives a title. If the user gives a title, use it verbatim (a trailing period is fine for a statement headline; ask if unsure).
- Looks alive, not generated. Demo data must read like a real team's week:
- Real-looking people with the project's own avatar photos if it ships any (e.g.
public/landing/people); use the names the user asks for. - Entities get icons or images, not bare letters (e.g. project avatars as colored icon tiles tinted with the product's theme accents).
- Activity grids, charts and counts follow real rhythms: busy Mon–Fri with variation, mostly empty weekends with the odd light day, the current week cut off at today, month labels where months actually start. Never a uniform or obviously repeating pattern.
- Relative times, IDs, branches and statuses in the formats the app uses.
- Real-looking people with the project's own avatar photos if it ships any (e.g.
- Copy leads. The title is the biggest, darkest thing on the card and readable at thumbnail size (~60–72px on a 1200px card, one line, tight tracking, the product's display font). The product sits below it and never overlaps it.
- Product's own style only. Background, fonts, colors, radii, shadows from the project's tokens. A very soft accent-tinted glow behind the title is fine; no new palettes, gradients or stock art.
Steps
1. Discover
- Read the homepage/landing component and README for the pitch, product name and sample content.
- Find the real app shell (layout, sidebar, header) and the primary screen (routes + components). Note exact class names, text sizes, tab labels, status chip tones, empty/loading states you must avoid.
- Find tokens (global CSS / theme), fonts, icon library, brand mark component, avatar assets.
- Check what's already there: an existing OG route/image,
og:imagemeta in the root or page head,WEB_URL/site URL config.
2. Build a render route
Build the card as a real page in the project's stack so it uses the actual fonts, tokens and components (not a hand-drawn SVG, not a screenshot of prod with private data):
- One route, e.g.
/og/<page>(TanStackroutes/og.<page>.tsx, Nextapp/og/<page>/page.tsx, etc.),noindex, no app chrome. - One component (e.g.
og-image.tsxnext to the landing it belongs to) rendering a fixed 1200×630 frame withdata-og-frameon the root andoverflow-hidden. - Layout:
- Brand mark centered, ~48px from the top.
- Title centered under it.
- App window starting ~200–240px from the top, ~60px from the left, wider than the remaining space so it bleeds off the right or bottom edge. Rounded top corners, hairline border, the product's shadow.
- Inside the window, rebuild the real screen as a static replica: shell (sidebar + header) plus the primary screen. Copy markup and classes from the real components; cite the source files in a header comment. Static props only, no queries, no timers.
- To fit a full-size layout into the card, lay the window out at its natural width (e.g. 1200px) and shrink it with
zoom(0.85–0.95).zoomalso scalestop/lefton the same element, so divide the intended offsets by the zoom factor. - Reuse existing demo primitives from the landing (avatars, source badges, heat colors) when they match the real app.
3. Capture
Start the dev server (or reuse one), then:
node <this skill folder>/scripts/capture.mjs \
--url http://localhost:<port>/og/<page> \
--out out/og-image/og-<page>.pngIt opens a 1200×630 viewport at 2x (→ 2400×1260), prefers reduced motion, hides dev overlays (TanStack/Next/Vite/Astro devtools, toasters), waits for fonts, and screenshots [data-og-frame]. Use --hide for any other overlay and --wait if images load slowly.
Gotchas:
- Port collisions: check the port is really serving this app (
lsof -iTCP:<port> -sTCP:LISTEN, and look at the page title). Another local app on[::1]:<port>can silently answerlocalhost. Pick a free port if needed. - A background dev server started from an agent session dies with the session. Detach it (
nohup … & disown) if the user needs to keep previewing. - Don't hide overlays with broad
:has()/body > divrules; they can hide the app root and time out the capture.
4. Look at it
Open the PNG and check it like a designer, at full size and imagining it at 500px wide:
- Title on one line, nothing overlapping it, generous space above the window.
- No devtools badges, cursors, toasts, loading skeletons, or half-played animations.
- Nothing clipped awkwardly (a label cut mid-word at a side edge, a chip half hidden). Bottom/right bleed is intended; left and top edges of the window are fully visible.
- Data looks real (rule 3). Iterate until it does, then copy the final PNG into
public/.
5. Wire the meta tags
On the page the image belongs to (or the root for a site-wide card):
og:type,og:title,og:descriptionog:image— absolute URL, built from the site URL config (e.g.${WEB_URL}/og-<page>.png)og:image:width2400,og:image:height1260,og:image:altdescribing title + what the product shot showstwitter:card=summary_large_image,twitter:title,twitter:description,twitter:image
Verify the tags appear in the served HTML (curl -s <page> | grep og:image) and the PNG URL returns 200 image/png.
Output
Tell the user:
- where the PNG and the render route/component live
- how to regenerate: the capture command above
- what the image shows and which real screens/components it replicates
- anything that isn't from real data (sample names, projects), and that the site URL env must point at the production domain for crawlers to resolve the image
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

