Guides / Extract

HTML → Markdown

POST /v1/html/to-markdown  · 

You already have the HTML: extract the readable article as Markdown — navigation, headers, footers, sidebars and scripts stripped. No browser, no network, milliseconds. The sibling of url/to-markdown.

Parameters

NameTypeDescription
htmlstring · requiredRaw HTML (or upload a file).
modestring · optionalarticle (default, strips navigation) or full.
baseUrlstring · optionalMakes relative links absolute.
outputstring · optionalmd (file, default) or json.

Example request

curl -X POST https://api.bigapi.dev/v1/html/to-markdown -H 'Authorization: Bearer $KEY' -H 'Content-Type: application/json' -d '{"html":"<h1>Title</h1><p>Text</p>"}' -o page.md

Example response

{
  "markdown": "# Quarterly report\n\nRevenue grew by **18 %**.\n\n| Region | Revenue |\n| --- | --- |\n| EU | 1.2m |",
  "title": "Quarterly report",
  "mode": "article"
}

When to use which

Use this when you already have the HTML — from your own fetch, a scraper or an email. If you only have a URL and the page needs JavaScript to render, use url/to-markdown instead: it renders the page in a real browser first.

Related guides