extractor.sh
All guides

Markdown extraction guide / 2026

URL to Markdown API for LLMs and RAG in 2026

Raw HTML spends tokens on scripts, navigation, styling, and interface labels. Clean Markdown keeps headings, paragraphs, lists, and links in a compact representation that models and chunking pipelines can use directly.

Quick answer

Convert a public URL into model-ready Markdown.

Pass a public URL to the extraction endpoint with format=markdown. The response removes interface noise, preserves useful hierarchy, and keeps the source URL available for attribution.

curl --get 'https://extractor.sh/api/extract' \
  --data-urlencode 'url=https://example.com/' \
  --data-urlencode 'format=json'

Available data

What you can extract

  • Readable headings, paragraphs, lists, and links
  • Canonical URL and public page metadata
  • Platform-aware entities for supported sources
  • A plain Markdown response for direct model input

AI workflows

Where normalized data helps

  • RAG document ingestion
  • Agent reading tools
  • Source-grounded summarization
  • LLM prompt context

AI-ready output

Markdown for models. JSON for systems.

Raw HTML consumes tokens on navigation, scripts, styling, and interface labels. Clean Markdown keeps the readable hierarchy for LLM prompts and RAG chunks. Normalized JSON is better when your application needs an explicit semantic type, source, author, publication date, media, attributes, and collection items.

Always retain the canonical URL from the response. AI-generated summaries should remain traceable to the public source, especially when the underlying page can change.

Boundaries

Public data only

  • Only publicly reachable GET URLs are accepted.
  • Login walls, paywalls, CAPTCHAs, and access controls are not bypassed.
  • Media transcripts, crawling, and authenticated content are outside the endpoint.

extractor.sh does not bypass CAPTCHAs, login walls, paywalls, access controls, or regional restrictions. Review the source’s terms and applicable law before collecting or reusing data.