/mailglow:mailglowfrom mailglow
Design, iterate and audit beautiful, responsive HTML emails with a local mini inbox. Use when the user wants to create an email template, redesign or improve transactional/notification/marketing emails, see how their app's emails look (Gmail, Outlook, Apple Mail, mobile, dark mode), compare design variants and pick one, lint an email for client compatibility, or screenshot every email a product sends. Triggers - "design an email", "email template", "make our emails look better", "preview emails", "how do our emails look", "email dark mode", "screenshot all emails", "vibe-code an email".
Ships in mailglow. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Design emails the way you'd design a screen: see them in an inbox, flip between variants, pick one, refine — and never ship something you haven't looked at in light, dark and mobile.
The engine is one zero-dependency Node script (Node ≥ 22; shoot also needs Chrome/Chromium/Edge):
VE="node <this-skill-dir>/scripts/mailglow.mjs" # resolve <this-skill-dir> to the folder holding this SKILL.md
$VE serve emails --open # mini inbox: list + opened message, live reload, variants, Pick + notes
$VE lint emails # client compatibility, exit 1 on any error (--net checks hosted images answer)
$VE shoot emails # PNG of every email × desktop/mobile × light/dark (+ the inbox view) + index.html
$VE new welcome emails --variants 3 # emails/welcome/{a,b,c}.html from the bulletproof starter
$VE picks emails # what the user picked in the inbox, and their notes per variant
$VE contract emails/welcome # after design: each {{field}} → the endpoint it comes from; what's missing
$VE fetch emails/welcome --base https://api… --name real-1 --param id=… # a data case from the real API
$VE stress emails/welcome --from real-1 # cases/stress-*.json (empty, emoji names, 600-char text…) + check every variant
A folder of emails is the whole interface: emails/welcome.html is one message;
emails/welcome/{a,b,c}.html is one message with three variants. Inbox metadata comes from
emails/manifest.json or <meta name="mail:subject|mail:from|mail:preheader"> in each file.
Nothing gets redesigned before the user has seen the current state in the inbox. Capture or write
first, serve, let them look. Then iterate. A redesign built on emails nobody opened is a guess.
No variant is drawn before the real data has been looked at. One tidy example ("Ana Torres", one clear message) designs an email for that example; production sends emoji-only names, "WhatsApp User" placeholders, 600-char notes, "ok" as the last message and no phone. Step R below is required, and a variant is judged by its worst case, not its best.
| The user has… | Mode |
|---|---|
| nothing yet ("design a welcome email") | A. New |
| emails in a codebase ("how do our emails look?", "make them better") | B. Capture, then C. Iterate |
| one email they want improved | C. Iterate |
Look for EMAIL-BRAND.md at the project root. If missing, write it with the user (ask only what the repo
can't tell you): product name and sender (Name <address>), hosted logo URL (https — never a repo
path), light + dark palette (background, card, ink, muted, accent, accent-ink), font stack with a system
fallback, voice (3 adjectives + 3 words it never uses), footer/legal line, the product's app URL. Every
email reads it. Template: references/email-brand-template.md.
Method and a worked catalogue: references/real-data-first.md.
cases/*.json; after the contract exists (D), run
$VE stress emails/<slug> --from <real-case> and add the catalogue's odd values as "stress": [...]
on their fields. Walk the cases with [ ] in the inbox; stress cases come after the real ones.If the user can't give access to real data, say what the design is blind to and ask for 10 examples pasted by hand — don't substitute invented ones silently.
$VE new <slug> emails --variants 3, then rewrite each variant as a structurally different answer
(different hierarchy, layout or primary affordance — not a recolor). If two come out alike, redo one
with an explicit "do not use X". Use references/design-principles.md and references/components.md.$VE lint emails → zero errors. Then serve and hand over the URL (see Hand-off).Emails built in code (f-strings, Jinja, React Email, MJML, a mailer class…) are captured by calling
the real builders, never by copying HTML by hand — a copy drifts the moment someone edits the code.
Write a small dump script next to the code that imports the builders, feeds them realistic fixture data,
intercepts the send seam, and writes <slug>.html + manifest.json (subject, from, preheader, trigger,
source: file:line). Recipe and a worked example: references/capture-existing.md.
Then: $VE lint <dir> → $VE shoot <dir> → open the screenshots yourself → serve for the user.
Report per email: what it is, when it fires, its lint errors, and what looks wrong in dark/mobile.
Typography-only rounds top out at "correct but plain". Rounds of images are cheap; rounds of HTML are not.
image-gen or equivalent).
A reference the user already made wins over yours — start from it.references/art-direction.md.references/anti-slop.md. It is a filter, not a style: a
detail executed as in the target (an eyebrow, an icon tile, a tinted card) stays; an unearned one goes./impeccable critique) and beauty /10 against the target image — "what detail of
the target is missing". Usability scores don't see "ugly". Fix P0/P1 first. Show both scores with the work.$VE contract <slug> per variant — existe / deriva (data exists, needs a rule or
endpoint) / falta (data doesn't exist) / sin origen — and say what each design would cost to build.a (emails/<slug>/a.html) so every round compares against it.
Step R done? Its catalogue is the brief the challengers answer.b, c…). Round 1 = structurally different; later rounds = targeted.lint → zero errors on every variant. serve; the user flips with ← →, presses Pick, and types
notes per variant. Those land in emails/picks.json.$VE picks emails. The notes are the brief for the next round — "header of b with the table of c"
is the actual design. Apply at most 3 changes per round so you know what helped.emails/<slug>.html, move the losers to
emails/.archive/<slug>/ (hidden from the inbox, kept as the record), shoot for evidence.Design first, freely — with realistic data typed in. Once a direction is picked (or when comparing variants whose cost matters), the email stops being a picture and becomes a template + contract:
{{contact.name}}, {{#messages}}…{{/messages}}, links
https://app…/inbox?c={{conversation.id}}, subject/preheader meta too. Syntax: references/data-contract.md.contract.json next to the variants: every field → the real endpoint and JSON path it comes
from (read the product's routes and schemas — cite them), status: "existe"; a field nothing provides
today → status: "falta" with the endpoint that should be built, a note and a sample.cases/*.json from real data: $VE fetch emails/<slug> --base <api> --name <case> --param id=… --header "Authorization: Bearer …" calls the endpoints that exist and falls back to samples for the rest.
Read-only credentials, staging first; real customer data never gets committed.$VE contract emails/<slug> prints fields × variants × source and the endpoints to build.
In the inbox, h toggles huecos: every field outlined green (exists), amber (endpoint missing),
red (no source) — hover shows the endpoint. This is how a variant's real cost is compared.$VE stress emails/<slug> --from <real-case> writes cases/stress-*.json from the
contract's field kinds (declare "kind" — name|text|longtext|phone|url|list|number|date — where the
inference is wrong, "stress": [...] for values from the catalogue) and renders every variant × case.
Findings: stress-unescaped / stress-leak (errors), stress-empty-join ("Hola ,", " te espera",
". Espera hace .") and stress-long-token (warnings). Fix the template or the builder's normalization,
then open the worst stress cases in the inbox ([ ]) — a finding-free render can still look broken.$VE contract emails/<slug> --strict exits 1 while any field has no declared source, and
$VE stress emails/<slug> --check --strict exits 1 while any variant breaks on a stress case. The
missing endpoints become issues/tasks before (or alongside) the port. $VE render gives the clean HTML.src is an absolute https:// URL that answers 2xx with an image type
(lint --net proves it). No relative paths, file:, localhost, or data: URIs. If the asset is
local, upload it first (the product's CDN/bucket, or a public repo's raw URL) — ask where.localhost from a dev .env.<style> only for progressive enhancement (mobile + dark).color-scheme meta + prefers-color-scheme + [data-ogsc].
Check both "Dark" (client honours your styles) and "Forced dark" (client inverts) in the inbox.position, flex/grid, CSS variables.stress proves it). User text cells carry overflow-wrap:anywhere so a 600-char word can't widen the card.Full rule list with the clients each protects: references/client-compat.md.
Give them the inbox URL and the keys: j/k mail · ← → variant · m mobile · d light/dark/forced ·
i images off · z fit ↔ 1:1 · h huecos (data sources) · [ ] case · l lint · p pick · n note. For async review, shoot and send shots/index.html (contact sheet).
Before saying anything looks good, open the PNGs — a screenshot is not evidence until you've looked at it.
references/art-direction.md — round 0 with an image model, replicating a target in layers, the hero band (art + flat colour), textless art, live script accents, fallbacks.references/design-principles.md — hierarchy, type, colour, dark mode, copy; the email anti-slop list.references/components.md — copy-paste blocks: button (+VML), stat tiles, key/value rows, list rows, 2-col stack, divider, footer, hosted image.references/client-compat.md — every lint rule, why it exists, which clients it protects.references/capture-existing.md — dump a product's real emails into the inbox.references/real-data-first.md — capture → catalogue with counts → rules → stress; required before variants.references/data-contract.md — template syntax, contract.json, cases, fetch, stress, huecos.references/email-brand-template.md — the EMAIL-BRAND.md skeleton.examples/ — finished emails in different directions; $VE serve <this-skill-dir>/examples to browse them.templates/starter.html — the bulletproof skeleton new copies.examples/alert.html (opens in a new tab)examples/digest.html (opens in a new tab)examples/receipt.html (opens in a new tab)examples/welcome.html (opens in a new tab)references/anti-slop.md (opens in a new tab)references/art-direction.md (opens in a new tab)references/capture-existing.md (opens in a new tab)references/client-compat.md (opens in a new tab)references/components.md (opens in a new tab)references/data-contract.md (opens in a new tab)references/design-principles.md (opens in a new tab)references/email-brand-template.md (opens in a new tab)references/real-data-first.md (opens in a new tab)scripts/lib/gallery.mjs (opens in a new tab)scripts/lib/install.mjs (opens in a new tab)scripts/lib/lint.mjs (opens in a new tab)scripts/lib/mailbox.mjs (opens in a new tab)scripts/lib/render.mjs (opens in a new tab)scripts/lib/server.mjs (opens in a new tab)scripts/lib/shoot.mjs (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub cofoundy/mailglow --plugin mailglow