html-to-markdown

html-to-markdown is a skill for Claude Code, Codex from appautomaton/webmaton. It costs 38 tokens per session (543 once invoked), scanned A, original, MIT.

A tool that turns a web address or HTML into clean Markdown, a plain-text format for structured documents, along with page metadata, links, images, and quality information. It can capture pages that require JavaScript before converting them.

In plain words
What is it for?
Use it to capture web pages, extract their main content, convert HTML to Markdown, and inventory the page's metadata, links, and images.
Why use it?
It removes the manual work of copying web content and cleaning up pages that do not expose their content as simple HTML.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/appautomaton/webmaton/html-to-markdown
Any agent
npx skills add appautomaton/webmaton --skill html-to-markdown
Clone the repo
git clone --depth 1 https://github.com/appautomaton/webmaton

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for html-to-markdown

README.md
[![agentmods](https://agentmods.dev/badge/skills/appautomaton/webmaton/html-to-markdown.svg)](https://agentmods.dev/skills/appautomaton/webmaton/html-to-markdown)
Your own site
<a href="https://agentmods.dev/skills/appautomaton/webmaton/html-to-markdown"><img src="https://agentmods.dev/badge/skills/appautomaton/webmaton/html-to-markdown.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 543 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00038 $0.00543
Opus 5 $0.00019 $0.00271
Sonnet 5 $0.00008 $0.00109
Haiku 4.5 $0.00004 $0.00054

Measured 5d ago against content hash 432e8d9d187f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

html-to-markdown scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/capture_html.py, scripts/markmaton_convert.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/html-to-markdown/SKILL.md · 58 lines

How it starts

The opening of the file, as written. The whole thing — 58 lines — stays where its author put it; the contents beside it link to each section on GitHub.

HTML to Markdown

Composes with

  • Use for — capture-a-web-page tasks where browser-rendered HTML or structured Markdown is needed.
  • Wraps — nodriver (CDP-based headless browser capture for JS-heavy pages, with Playwright Chromium discovery) and markmaton (HTML→Markdown with main-content extraction, metadata, and link/image inventory). See references/integration-patterns.md for browser-vs-fetch guidance.
  • Outputs — JSON envelope by default (markdown body + metadata + links + images + quality signals). Use --output-format markdown when only the raw Markdown body is needed.

Converts a URL or HTML into clean Markdown plus metadata, links, images, and quality signals.

From a URL

Capture the page and convert in one pipeline:

uv run --script scripts/capture_html.py <url> \
  | uv run --script scripts/markmaton_convert.py --from-capture --output-format json

The capture script outputs a JSON envelope by default. --from-capture reads it and extracts html, url, final_url, and content_type automatically — no context lost, URL typed once.

  • Add --wait-selector <css> or --wait-text <string> to the capture step for pages that need a readiness signal.
  • Prefer a simple fetch over browser capture for static articles, wikis, and server-rendered docs.

From HTML

uv run --script scripts/markmaton_convert.py --html-file page.html \
  --url <url> --output-format json

Or from stdin:

echo "$html" | uv run --script scripts/markmaton_convert.py --url <url>

Pass --url when available — it improves link resolution and canonical metadata.

Key defaults

  • Output: json. Use --output-format markdown for raw Markdown only.
  • Main-content extraction: on. Use --full-content to disable.
  • Capture: always headless. Timeout 10s, override with --timeout.
  • Browser discovery: user's Chrome → user's Chromium → Playwright's Chromium.

References

Read only when needed:

  • references/usage.md — full CLI reference for both scripts
  • references/integration-patterns.md — browser vs fetch guidance, contracts, parser defaults

Read the full file on GitHub · 58 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 58 lines · 38 tokens per session scan A 432e8d9d187f

Subscribe to this mod's changes

html-to-markdown is a skill published in the GitHub repository appautomaton/webmaton (19 stars, last pushed 10d ago), licensed MIT. It adds 38 tokens to every session and 543 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

browser-use

Direct browser control via CDP for web interaction: automation, scraping, testing, screenshots, and site/app work.

browser-use/browser-use · 26 tokens

auto-research

Research uncertain questions with an explicit, user-approved web search or ChatGPT consultation, then present options and wait for implementation approval.

sickn33/agentic-awesome-skills · 29 tokens

opencli-autofix

Automatically fix broken OpenCLI adapters when commands fail. Load this skill when an opencli command fails — it guides you through collecting a trace artifact, patching the adapter, retrying, and filing an upstream GitHub issue after a verified fix. Works with any AI agent.

jackwener/OpenCLI · 61 tokens

opencli-sitemap-author

Use when creating or maintaining OpenCLI site sitemaps: agent-facing navigation, page-state, action, workflow, API-reference, pitfall, and fallback knowledge for a website. Use after browser exploration discovers durable site context, when a sitemap is stale, or when promoting local site knowledge into the repo.

jackwener/OpenCLI · 67 tokens

opencli-browser-sitemap

Use when driving a website with opencli browser and sitemap context is available, requested, or needed to avoid blind navigation. Guides agents to consume site sitemap files lazily, choose adapter/browser fallback paths, resume from state signatures, and mark stale sitemap entries without trusting them over live…

jackwener/OpenCLI · 64 tokens

pinchtab

Use this skill when a task needs browser automation through PinchTab: open a website, inspect interactive elements, click through flows, fill out forms, scrape page text, reuse a dedicated automation profile with user approval, export screenshots or PDFs, manage multiple browser instances, or fall back to the HTTP API…

pinchtab/pinchtab · 94 tokens