πŸ’»β€‚CLI

Which command do I run, and what are its flags?

12 min readView as markdown
npx @getnarro/cli <command>

Install it globally (npm i -g @getnarro/cli) and the binary is narro.

npx narro resolves an unrelated package on npm. Use npx @getnarro/cli, or install globally and call narro.

Commands

CommandWhat it does
narro analyze-slides-for-componentsAnalyze presentation slides to identify needed shared-ui components
narro annotate <file>Bake a notes track into a recording β€” captions, callouts and spotlights
narro build [file]Build for production (pass a .md file for markdown mode)
narro bundleBundle presentation into a single self-contained HTML file
narro capture-website <url>Capture a full-page screenshot of a website
narro cast <file>Read a recording back β€” its shape, its length, and the chapters it carries
narro check <file|dir>Validate a markdown deck, or measure built output with --fit
narro commentsManage slide comments
narro create [project-name]Create a new Narro presentation project
narro create-template-from-screenshots [template-name]Generate a template from presentation screenshots using AI
narro dev [file]Start development server (pass a .md file for markdown mode)
narro export [file]Export presentation to static files, PPTX, or Google Slides
narro fmt <file>Normalise a deck’s whitespace and frontmatter without changing what it renders
narro import <source>Import presentation from PowerPoint or Google Slides
narro new <file>Scaffold a starter markdown deck
narro notes <file>Draft a narration track from a transcript, resolving what it points at
narro previewPreview built presentation
narro record <url>Record a web app into an embeddable cast β€” real DOM, not video
narro review <file>Review a recording β€” dead clicks, dead air, unreadable type, leaked input
narro themesBrowse and apply themes from the marketplace

Reference

Generated from the command tree, so it cannot disagree with narro --help.

narro analyze-slides-for-components

Analyze presentation slides to identify needed shared-ui components

OptionFor
-d, --screenshots-dir <dir>Directory containing screenshot files
-s, --screenshots <paths...>Screenshot file paths
-o, --output <file>Output markdown file
-p, --provider <provider>AI provider (openai or claude)
-m, --model <model>AI model to use

narro annotate <file>

Bake a notes track into a recording β€” captions, callouts and spotlights

OptionFor
-n, --notes <path>the track to bake in, a .notes.md
-o, --out <path>write here instead of over the recording
--clearremove the track the recording is carrying
--uiopen the editor, over the track the recording already has
--port <number>the port the editor listens on

narro build [file]

Build for production (pass a .md file for markdown mode)

OptionFor
-o, --outDir <dir>output directory
--base <path>base path for deployment
--no-fitskip the overflow measurement after building

narro bundle

Bundle presentation into a single self-contained HTML file

OptionFor
-o, --output <filename>output filename
--minifyminify output for smaller file size
--inline-assetsinline images as base64 (default: false)
--check-sizewarn if output exceeds email attachment limit (~25MB)

narro capture-website <url>

Capture a full-page screenshot of a website

OptionFor
-o, --output <path>Output file path (default: screenshot.png)
-f, --full-pageCapture full page (scrollable content)
-w, --width <number>Viewport width in pixels
-h, --height <number>Viewport height in pixels
-d, --delay <number>Delay before screenshot in milliseconds

narro cast <file>

Read a recording back β€” its shape, its length, and the chapters it carries

OptionFor
--jsonprint the summary as JSON

narro check <file|dir>

Validate a markdown deck, or measure built output with --fit

OptionFor
--stricttreat warnings as errors
--renderprint what each slide renders β€” elements, classes, and text
--fitrender the deck in a headless browser and report slides whose content overflows
--fit-if-availablelike --fit, but only warn when no browser is installed
--render-fulllike --render, but print long text and large props in full

narro comments

Manage slide comments

narro create [project-name]

Create a new Narro presentation project

OptionFor
-t, --template <template>Template to use (minimal, corporate, developer, creative, bold-statement, visual-story, data-narrative, startup-pitch, tech-conference, template0, markdown-minimal, markdown-app, markdown-docs)
-m, --mode <mode>Presentation mode: react (default) or markdown
--skip-installSkip npm install
-y, --yesAccept the defaults for anything not given; never prompt
--forceScaffold into a directory that already has files in it
--listList every template with what it is, and exit

narro create-template-from-screenshots [template-name]

Generate a template from presentation screenshots using AI

OptionFor
-s, --screenshots <paths...>Screenshot file paths
-o, --output <dir>Output directory
-p, --provider <provider>AI provider (openai or claude)
-m, --model <model>AI model to use

narro dev [file]

Start development server (pass a .md file for markdown mode)

OptionFor
-p, --port <number>port to use
--hostexpose to network
-o, --openopen browser on startup
--no-opendo not open the browser (markdown mode)
--theme <name>theme override (markdown mode)

narro export [file]

Export presentation to static files, PPTX, or Google Slides

OptionFor
-o, --outDir <dir>output directory for HTML export
--pdfexport to PDF (requires Playwright)
--pngexport slides as PNG images (requires Playwright)
--to <format>export format: pptx, google-slides
--output-path <path>output file path for PPTX export
--include-notesinclude speaker notes in export
--include-animationsinclude animations in export
--settle <ms>milliseconds to let a slide’s animations finish before capturing (default: 4000)
--input-path <path>path to presentation project
--template-path <path>PowerPoint template file (.potx or .pptx) to apply
--template-id <id>Google Slides template presentation ID to copy from
--google-client-id <id>Google OAuth client ID
--google-client-secret <secret>Google OAuth client secret
--google-refresh-token <token>Google OAuth refresh token

narro fmt <file>

Normalise a deck’s whitespace and frontmatter without changing what it renders

OptionFor
--checkreport whether the deck is formatted, and exit non-zero if not

narro import <source>

Import presentation from PowerPoint or Google Slides

OptionFor
--from <source>import source: pptx, google-slides
-o, --output-dir <dir>output directory for imported project
--preserve-stylespreserve original styles
--convert-animationsconvert animations
--google-client-id <id>Google OAuth client ID
--google-client-secret <secret>Google OAuth client secret
--google-refresh-token <token>Google OAuth refresh token

narro new <file>

Scaffold a starter markdown deck

narro notes <file>

Draft a narration track from a transcript, resolving what it points at

OptionFor
-f, --from <path>the transcript: WebVTT, SRT, or Whisper’s JSON
-o, --out <path>where to write the draft (default: beside the recording)
--offset <ms>shift the transcript, when it and the recording started apart
--rawkeep the transcript’s own cue lengths instead of joining sentences

narro preview

Preview built presentation

OptionFor
-p, --port <number>port to use
--hostexpose to network
-o, --openopen browser on startup
-d, --outDir <dir>serve a directory of built output directly

narro record <url>

Record a web app into an embeddable cast β€” real DOM, not video

OptionFor
-o, --out <path>where to write the cast
--size <WxH>recording viewport β€” the window is sized to match
--connect [endpoint]record a Chrome you already have open, signed in, with your extensions β€” start it with --remote-debugging-port and a --user-data-dir of its own
--auto <seconds>record headless, scrolling the page, instead of opening a window
--maskmask input values and drop scripts and comments
--chapters <path>a JSON file of named marks β€” [{ β€œname”: β€œpublish”, β€œatMs”: 4200 }] β€” for the recordings no one is sitting through
--mic [path]also capture the operator’s narration, for a transcript to draft a track from (needs ffmpeg)
--transcribe [binary]run a Whisper-shaped binary over what --mic caught (default: whisper-cli)
--notes <path>a .notes.md track to bake in β€” captions, callouts and spotlights over the recording
--html <path>also write a standalone page that plays it
--embed <dir>also write the player, the cast and a snippet for a website
--poster <path>also write a PNG of the last frame, for PDF and PPTX export
--cursor <mode>pointer, trail or none
--no-optimizekeep images exactly as the page served them
--promptprint the prompt for a coding agent without asking first

narro review <file>

Review a recording β€” dead clicks, dead air, unreadable type, leaked input

OptionFor
--rules <list>a comma-separated subset (leaked-input, dead-click, dead-air, scroll-rush, illegible, unchaptered, chapter-gap)
--strictfail on warnings too, not only on errors
--out <path>also write the briefing, for a person or a coding agent
--embed-width <px>the width the demo will be shown at, for legibility
--jsonprint the findings as JSON

narro themes

Browse and apply themes from the marketplace

Notes

check is the CI gate. narro check deck.md --strict promotes warnings to errors and exits non-zero, which is the step a pipeline runs β€” the scaffolded markdown templates map their lint script to exactly that. Plain check exits 0 on warnings, which makes it the right form for the edit loop and the wrong form for CI.

Three flags, three different questions:

FlagAnswers
--renderWhat does the slide render, and did that class land on the word or the paragraph? No browser.
--strictIs anything at all wrong, including the warnings? Exit code for CI.
--fitDoes the content fit the canvas β€” and does the page render at all? The only check that opens a browser. Not implied by --strict.
--fit-if-availableThe same, but a missing browser is a warning rather than a failure

See Verifying a deck for what each of these sees and does not see.

narro build <deck>.md measures fit for you. A single-file deck has no package.json to wire a check into, so the build runs one: it reports the overflow and exits non-zero. A machine with no browser gets a warning rather than a failure β€” narro check dist --fit is the strict form β€” and --no-fit turns it off entirely. This is the only fit check a narro new deck gets, because it is the only place there is to put one.

--fit and React mode. check is markdown-only, but --fit measures built output: npm run build && npx @getnarro/cli check dist --fit works for a React deck and is the only fit check either mode has. Every React template ships a fit script that runs exactly that. It needs Chromium (npx playwright install chromium); without one it fails, because a check that measured nothing is not a check that passed. --fit-if-available makes that a warning when you want it to be one, and NARRO_CHROMIUM=/path/to/chromium points it at a browser your image already has.

Formatting. Use narro fmt, not Prettier β€” a markdown formatter can reflow a paragraph and move an attribute block onto its own line, which changes what it styles with nothing to report it. See Formatting a deck.

Scaffolding. npm create narro@latest my-deck and narro create my-deck run the same code. narro new deck.md is different: it writes a single markdown file with no project around it.

Markdown mode. Passing a .md file to dev or build switches to markdown mode, where no project or config file is needed β€” the CLI brings its own runtime.

Export fidelity. A static build keeps animations, embeds, and live components working. PPTX maps slides onto real PowerPoint shapes so text stays editable, but anything driven by a live component becomes its rendered state. PDF flattens fragments to their final state.

Credentials. Google Slides import and export need Google OAuth credentials in the environment. create-template-from-screenshots and analyze-slides-for-components call a hosted vision model and need ANTHROPIC_API_KEY or OPENAI_API_KEY.

IntroductionWhat is Narro, and should I be writing markdown or React?
InstallationWhat do I install, and what does the project look like afterwards?
First DeckWhat does a working React deck look like, end to end?
Markdown ModeHow do I split a slide, style one word, or reveal a line β€” without leaving the markdown file?
Writing AI PromptsWhat do I tell an AI so the deck it writes actually builds?
Rules for AI AgentsWhat do I paste into my repo so an agent stops writing decks that build wrong?
React APIWhich component or hook do I import, and what does it take?
CLIWhich command do I run, and what are its flags?
Markdown APIHow do I read, edit, or validate a deck file from my own code instead of by hand?
Component ReferenceWhat props does this component take, and which package do I import it from?
Verifying a deckHow do I know my deck is actually correct?
AnimationHow do I reveal a list one line at a time, or move between slides with something other than a cut?
NavigationHow does the audience move through the deck, and how do I present it?
Canvas & PositioningHow do I put something at an exact position instead of in the flow?
Images & MediaHow do I use an image as a background, tint it, or embed a video?
ArchitectureWhich package owns what, and why is the seam where it is?
Zooming canvasHow do I zoom and pan across one big canvas instead of cutting between slides?
Transform ModeHow do I zoom and pan across one big canvas instead of cutting between slides?
Import & ExportHow do I get this deck out as PPTX, PDF, or one file I can email?
VideoHow do I turn a story into a video, and keep it right when the words, the product or the source changes?
Recording a web appHow do I put a demo of my product in a deck or on a landing page without shipping a video of it?
Embedding a replayHow do I embed a recorded demo of my app in my React app, my Astro site, or any other page?
TerminalHow do I put a terminal demo in a deck, a README or a video, and find out when the tool it demonstrates stops saying what the demo says?
AI IntegrationHow do I wire an AI assistant up to Narro so it can write and build decks?
ThemingHow do I change the colours, fonts, and overall look of a deck?
Deck TemplatesHow do I define one house style with named layouts my slides can reference, like a PowerPoint master?
TroubleshootingSomething is wrong with my deck. What is it, and how do I fix it?
LimitationsWhat can't Narro do, and what do I do instead?