Command Line

Any URL to Markdown, from your terminal

Markdown goes to stdout, so it composes with everything you already use — pipe it into an LLM, redirect it to a file, or batch a whole list of URLs into a research folder. No install required.

npx web2md-cli https://example.com

The short answer

Run npx web2md-cli <url> and you get clean Markdown on stdout. Add --batch for a file of URLs, --json for scripting, and login for sites that need authentication. The official npm package is web2md-cli.

Get started

Try it right now — nothing to install, nothing to clean up.

1. Convert a page

npx web2md-cli https://example.com

Markdown goes to stdout, so you can pipe or redirect it anywhere.

Recipes

Pipe a page straight into an LLM

npx web2md-cli https://news.ycombinator.com/item?id=123 | llm "summarize"

Save with YAML frontmatter

npx web2md-cli https://example.com --meta -o article.md

Batch convert a file of URLs, resumably

npx web2md-cli --batch urls.txt --output-dir ./research --concurrency 5 --resume

JSON output for scripting

npx web2md-cli https://example.com --json | jq '.metadata.wordCount'

Sync into a local vault

npx web2md-cli --batch urls.txt --vault ~/Documents/Research

Questions

Do I need to install anything?

No. npx web2md-cli <url> runs without a global install. Install it globally with npm install -g web2md-cli if you use it often and want the shorter web2md command.

What is the correct package name?

The official package is web2md-cli. The unscoped web2md package on npm is an unrelated project, so install web2md-cli specifically.

Do I need an API key?

Not for ordinary public pages. For Reddit and other restricted sites, run npx web2md-cli login, or set WEB2MD_API_KEY in your environment. Free keys work; paid plans raise the quota.

Can it convert pages I am logged in to?

Use the MCP server with the Chrome extension for that. The CLI fetches pages directly, so it suits public and API-reachable content; the browser bridge is what reaches your authenticated sessions.

Does it work in CI?

Yes. Set WEB2MD_API_KEY as a secret and call the CLI from your pipeline. Use --json or --ndjson for machine-readable output and --resume for long batches.

Also available

Want your agent to call Web2MD directly instead of shelling out?