# scrapy/parsel

Parsel lets you extract data from XML/HTML documents using XPath or CSS selectors

Repository: https://github.com/scrapy/parsel
Canonical: https://ross.abutalabs.com/products/parsel
Language: Python
License: BSD-3-Clause
License Family: permissive
Topics: python, lxml, xpath, xml, selectors, css, scraping, hacktoberfest
Last push: 2026-08-25T10:23:07+00:00

## Health v2 (maintenance only)
Score: 88/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 99, release rhythm 68, longevity 100
- inputs: {"age_days": 4149, "days_push": 8, "days_rel": 216, "gap_med": 0, "n_releases_24m": 4}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1352, forks 168 (observed 2026-08-28T04:04:28.439796+00:00)

## What it is
Parsel is a BSD-licensed Python library for extracting data from HTML, XML, and JSON documents using CSS selectors, XPath expressions, JMESPath, and regular expressions. It is built on lxml and serves as the selector engine behind the Scrapy framework.

## Use cases
- extract data from html with css selectors
- parse xml documents with xpath in python
- scrape links and text from web pages
- query json embedded in html with jmespath
- extract values from html using regular expressions
- build a web scraper selector layer

## When to choose
- you need CSS or XPath extraction from HTML/XML in Python
- you want a lightweight standalone alternative to full Scrapy
- you need to query JSON with JMESPath alongside HTML parsing

## When to avoid
- you need a full crawling framework with scheduling and pipelines
- you are parsing non-HTML/XML formats like binary documents
- you need JavaScript-rendered page content

## Facets
- artifact type: library
- maturity: active
- function: parser, web-scraping
- domain: web-development, crawlers, developer-tools
- platform: python, cross-platform
- tags: xpath, css-selectors, html-parsing, xml-parsing, jmespath, lxml, scrapy

## Member repositories
- scrapy/parsel (main) score 88

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:28.439796+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-30T04:42:10.963608+00:00, confidence not recorded.
  - readme: https://github.com/scrapy/parsel (fetched 2026-08-28T04:04:28.439796+00:00, sha c0dfe547375d)
  - registry_pypi: https://pypi.org/pypi/parsel/json (fetched 2026-08-29T12:00:42.378097+00:00, sha 5d2d8e154d9b)
- Data as of 2026-08-30T08:39:29.467469+00:00.
