Marp Deck Authoring
Use this skill to create or reshape a slide deck in Marp Markdown. Focus on slide structure, Markdown authoring, directives, asset organization, and export workflow.
Quick routing
| Situation |
What to do |
| Create a new Marp deck from scratch |
Start from assets/starter-deck.md, then adapt the flow and content. |
| Turn an existing doc into slides |
Use headingDivider if the source is already well-structured, otherwise rewrite into slide-sized chunks. |
| User needs theme CSS or a custom visual system |
Use this skill for deck structure, and consult marp-css for theme work. |
| User wants export commands or local preview |
Give Marp CLI or Marp for VS Code guidance. |
| User mentions folders, assets, or project layout |
Use the recommended directory layout in this skill. |
Workflow
- Inspect the source material before writing slides.
- Infer the audience, goal, and presentation length from the prompt and files.
- Decide the deck shape before drafting:
- title / hook
- context or problem
- evidence or analysis
- proposal / solution
- next steps / summary
- Write one clear idea per slide. Prefer strong headings over dense paragraphs.
- Set up Marp frontmatter and directives early so the deck is runnable immediately.
- Use relative paths for images and themes so the deck works across preview and export workflows.
- Keep styling lightweight in the Markdown itself. If the user needs reusable styling or a redesign, hand that part to
marp-css.
Authoring rules
1. Start with valid Marp frontmatter
Use frontmatter when creating a deck unless the user already has a preferred format.
---
marp: true
theme: default
paginate: true
---
marp: true enables Marp features in Marp for VS Code.
theme selects the active theme.
paginate enables page numbers when the theme supports them.
- For Marp Core decks,
size is available as a global directive, such as size: 4:3.
2. Separate slides with rulers
Use --- between slides.
# Slide 1
Content
---
# Slide 2
If the source document is plain Markdown with consistent headings, headingDivider can be cleaner than inserting rulers everywhere.
---
marp: true
headingDivider: 2
---
3. Use directives deliberately
Useful directives to reach for first:
- global:
theme, style, headingDivider, lang
- local:
paginate, header, footer, class
- slide styling:
backgroundColor, backgroundImage, backgroundSize, color
- Marp Core additions:
size, math
Use spot directives with a leading underscore when the change should affect only one slide.
<!-- _class: lead -->
<!-- _paginate: false -->
4. Prefer slide-native image syntax
Use Marpit image syntax instead of HTML hacks when it expresses the layout clearly.




![bg] sets a slide background.
left / right create split-background layouts.
left:33% or right:40% controls split width.
w: / h: set image size with stable units.
5. Keep slides presentation-sized
- Prefer 1 message per slide.
- Keep bullets short and parallel.
- Split crowded slides instead of shrinking text.
- Convert long prose into headings, short bullets, tables, diagrams, or comparison layouts.
- Use section divider slides to reset attention in longer decks.
6. Use inline style sparingly
- Use
<style scoped> only for a one-slide exception.
- Use a shared theme CSS file for repeated styling.
- If styling becomes a main task, route that work to
marp-css.
Recommended deck structures
Story-first business deck
- Title / promise
- Why this matters now
- Current state or problem
- Evidence / data / examples
- Proposed approach
- Impact / tradeoffs
- Next steps
Technical explanation deck
- Title / scope
- System context
- Current architecture or problem
- Key design decisions
- Flow, sequence, or API examples
- Risks and mitigations
- Rollout / action items
Training or workshop deck
- Title / objective
- Audience prerequisites
- Agenda
- Concepts
- Demo or worked example
- Practice or checklist
- Summary / references
Recommended directory layout
This is a practical convention for Marp projects, not an official requirement.
slides/
deck.md
themes/
brand.css
images/
hero.png
diagrams/
data/
snippets/
exports/
Use it like this:
slides/deck.md: main deck entry point
slides/themes/: reusable Marp theme CSS
slides/images/: screenshots, diagrams, logos, photography
slides/data/: CSV or JSON used to generate charts or tables
slides/snippets/: reused Markdown fragments or raw HTML fragments if the workflow needs them
slides/exports/: generated .html, .pdf, .pptx, or images
If the workspace uses Marp for VS Code and custom themes, register theme files in .vscode/settings.json with markdown.marp.themes.
Output requirements
When the user wants deck content, produce:
- The Marp Markdown deck.
- Any required frontmatter or directives.
- Relative asset paths that match the workspace layout.
- Brief notes about missing assets or placeholders only when needed.
When the user wants a plan before writing slides, provide:
- the deck outline,
- the intended slide count,
- any assumptions about audience or tone.
Export and preview guidance
Prefer the simplest workflow already available in the workspace.
Marp for VS Code
- Add
marp: true in frontmatter.
- Use the preview while editing.
- Export from the Marp command if the extension is installed.
Marp CLI
npx @marp-team/marp-cli@latest slides/deck.md
npx @marp-team/marp-cli@latest slides/deck.md --pdf -o slides/exports/deck.pdf
npx @marp-team/marp-cli@latest slides/deck.md --pptx -o slides/exports/deck.pptx
- HTML export is the default.
- PDF, PPTX, and image export require a supported browser.
- If local images must be resolved during browser-based export,
--allow-local-files may be required for trusted content.
Avoid
- Writing document-length prose onto slides.
- Mixing too many layout ideas on one slide.
- Using absolute-position HTML for ordinary content when Markdown or Marp image syntax is enough.
- Treating the recommended directory layout as mandatory.
- Solving a theme-design problem only with Markdown structure when
marp-css is the better tool.
Bundled resources
- Read
references/marp-authoring-reference.md for exact syntax reminders and directory guidance.
- Start from
assets/starter-deck.md when the user needs a clean Marp scaffold fast.
1---2name: marp-deck3description: Use this skill whenever the user wants to create, outline, rewrite, or organize a presentation in Marp or Marpit Markdown. Trigger on requests to turn notes, docs, READMEs, specs, or outlines into slide Markdown; set up `marp: true` frontmatter; choose slide structure, directives, backgrounds, speaker flow, asset folders, or export commands; or build a new Markdown slide deck from scratch. Use it even when the user says 'presentation', 'deck', or 'slides' without naming Marp explicitly but the desired output is a Marp Markdown deck. If the task is mainly theme CSS or visual restyling, also consult `marp-css`.4license: Proprietary. LICENSE has complete terms.5---67# Marp Deck Authoring89Use this skill to create or reshape a slide deck in Marp Markdown. Focus on slide structure, Markdown authoring, directives, asset organization, and export workflow.1011## Quick routing1213| Situation | What to do |14| --- | --- |15| Create a new Marp deck from scratch | Start from `assets/starter-deck.md`, then adapt the flow and content. |16| Turn an existing doc into slides | Use `headingDivider` if the source is already well-structured, otherwise rewrite into slide-sized chunks. |17| User needs theme CSS or a custom visual system | Use this skill for deck structure, and consult `marp-css` for theme work. |18| User wants export commands or local preview | Give Marp CLI or Marp for VS Code guidance. |19| User mentions folders, assets, or project layout | Use the recommended directory layout in this skill. |2021## Workflow22231. Inspect the source material before writing slides.242. Infer the audience, goal, and presentation length from the prompt and files.253. Decide the deck shape before drafting:26 - title / hook27 - context or problem28 - evidence or analysis29 - proposal / solution30 - next steps / summary314. Write one clear idea per slide. Prefer strong headings over dense paragraphs.325. Set up Marp frontmatter and directives early so the deck is runnable immediately.336. Use relative paths for images and themes so the deck works across preview and export workflows.347. Keep styling lightweight in the Markdown itself. If the user needs reusable styling or a redesign, hand that part to `marp-css`.3536## Authoring rules3738### 1. Start with valid Marp frontmatter3940Use frontmatter when creating a deck unless the user already has a preferred format.4142```markdown43---44marp: true45theme: default46paginate: true47---48```4950- `marp: true` enables Marp features in Marp for VS Code.51- `theme` selects the active theme.52- `paginate` enables page numbers when the theme supports them.53- For Marp Core decks, `size` is available as a global directive, such as `size: 4:3`.5455### 2. Separate slides with rulers5657Use `---` between slides.5859```markdown60# Slide 16162Content6364---6566# Slide 267```6869If the source document is plain Markdown with consistent headings, `headingDivider` can be cleaner than inserting rulers everywhere.7071```markdown72---73marp: true74headingDivider: 275---76```7778### 3. Use directives deliberately7980Useful directives to reach for first:8182- global: `theme`, `style`, `headingDivider`, `lang`83- local: `paginate`, `header`, `footer`, `class`84- slide styling: `backgroundColor`, `backgroundImage`, `backgroundSize`, `color`85- Marp Core additions: `size`, `math`8687Use spot directives with a leading underscore when the change should affect only one slide.8889```markdown90<!-- _class: lead -->91<!-- _paginate: false -->92```9394### 4. Prefer slide-native image syntax9596Use Marpit image syntax instead of HTML hacks when it expresses the layout clearly.9798```markdown99100101102103```104105- `![bg]` sets a slide background.106- `left` / `right` create split-background layouts.107- `left:33%` or `right:40%` controls split width.108- `w:` / `h:` set image size with stable units.109110### 5. Keep slides presentation-sized111112- Prefer 1 message per slide.113- Keep bullets short and parallel.114- Split crowded slides instead of shrinking text.115- Convert long prose into headings, short bullets, tables, diagrams, or comparison layouts.116- Use section divider slides to reset attention in longer decks.117118### 6. Use inline style sparingly119120- Use `<style scoped>` only for a one-slide exception.121- Use a shared theme CSS file for repeated styling.122- If styling becomes a main task, route that work to `marp-css`.123124## Recommended deck structures125126### Story-first business deck1271281. Title / promise1292. Why this matters now1303. Current state or problem1314. Evidence / data / examples1325. Proposed approach1336. Impact / tradeoffs1347. Next steps135136### Technical explanation deck1371381. Title / scope1392. System context1403. Current architecture or problem1414. Key design decisions1425. Flow, sequence, or API examples1436. Risks and mitigations1447. Rollout / action items145146### Training or workshop deck1471481. Title / objective1492. Audience prerequisites1503. Agenda1514. Concepts1525. Demo or worked example1536. Practice or checklist1547. Summary / references155156## Recommended directory layout157158This is a practical convention for Marp projects, not an official requirement.159160```text161slides/162 deck.md163 themes/164 brand.css165 images/166 hero.png167 diagrams/168 data/169 snippets/170 exports/171```172173Use it like this:174175- `slides/deck.md`: main deck entry point176- `slides/themes/`: reusable Marp theme CSS177- `slides/images/`: screenshots, diagrams, logos, photography178- `slides/data/`: CSV or JSON used to generate charts or tables179- `slides/snippets/`: reused Markdown fragments or raw HTML fragments if the workflow needs them180- `slides/exports/`: generated `.html`, `.pdf`, `.pptx`, or images181182If the workspace uses Marp for VS Code and custom themes, register theme files in `.vscode/settings.json` with `markdown.marp.themes`.183184## Output requirements185186When the user wants deck content, produce:1871881. The Marp Markdown deck.1892. Any required frontmatter or directives.1903. Relative asset paths that match the workspace layout.1914. Brief notes about missing assets or placeholders only when needed.192193When the user wants a plan before writing slides, provide:1941951. the deck outline,1962. the intended slide count,1973. any assumptions about audience or tone.198199## Export and preview guidance200201Prefer the simplest workflow already available in the workspace.202203### Marp for VS Code204205- Add `marp: true` in frontmatter.206- Use the preview while editing.207- Export from the Marp command if the extension is installed.208209### Marp CLI210211```bash212npx @marp-team/marp-cli@latest slides/deck.md213npx @marp-team/marp-cli@latest slides/deck.md --pdf -o slides/exports/deck.pdf214npx @marp-team/marp-cli@latest slides/deck.md --pptx -o slides/exports/deck.pptx215```216217- HTML export is the default.218- PDF, PPTX, and image export require a supported browser.219- If local images must be resolved during browser-based export, `--allow-local-files` may be required for trusted content.220221## Avoid222223- Writing document-length prose onto slides.224- Mixing too many layout ideas on one slide.225- Using absolute-position HTML for ordinary content when Markdown or Marp image syntax is enough.226- Treating the recommended directory layout as mandatory.227- Solving a theme-design problem only with Markdown structure when `marp-css` is the better tool.228229## Bundled resources230231- Read `references/marp-authoring-reference.md` for exact syntax reminders and directory guidance.232- Start from `assets/starter-deck.md` when the user needs a clean Marp scaffold fast.