# aaronsw/html2text

Convert HTML to Markdown-formatted text.

Repository: https://github.com/aaronsw/html2text
Canonical: https://ross.abutalabs.com/products/html2text
Homepage: http://www.aaronsw.com/2002/html2text/
Language: Python
License: GPL-3.0
License Family: copyleft
Last push: 2024-02-27T18:49:46+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 5696, "days_push": 918, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2813, forks 420 (observed 2026-08-28T04:07:23.766617+00:00)

## What it is
html2text is a Python script and library that converts HTML pages into clean plain ASCII text that is also valid Markdown. It can be used from the command line with files or URLs, or programmatically via its Python API with configurable options.

## Use cases
- convert an HTML page to Markdown text
- extract readable plain text from a web page URL
- strip links and images from HTML when converting to text
- use html2text inside a Python script to transform HTML strings
- convert exported Google Documents to Markdown
- preprocess scraped HTML into Markdown for storage or LLM input

## When to choose
- you need HTML-to-Markdown conversion in Python or from the CLI
- you want configurable output like ignoring links, wrapping width, or list styles
- you want a small, mature, well-known tool with a simple API

## When to avoid
- you need the reverse conversion (Markdown to HTML)
- you need a non-Python implementation
- you require a permissive license, since it is GPL-3.0

## Facets
- artifact type: library
- maturity: active
- function: parser, markdown, cli
- domain: web-development, developer-tools
- platform: python, cli, cross-platform
- tags: html-to-markdown, text-conversion, html-parsing, ascii-output, command-line

## Member repositories
- aaronsw/html2text (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:23.766617+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T08:13:29.779046+00:00, confidence not recorded.
  - readme: https://github.com/aaronsw/html2text (fetched 2026-08-28T04:07:23.766617+00:00, sha 85d4949a9955)
  - homepage: http://www.aaronsw.com/2002/html2text/ (fetched 2026-08-29T09:54:01.570540+00:00, sha f39dcf9d2eea)
- Data as of 2026-08-30T08:39:29.467469+00:00.
