petl
A Python package for extracting, transforming and loading tables of data.
What it is and what it does
petl is a Python library for building data pipelines using a declarative, chainable API. It lets you extract data from various sources, apply transformations (filtering, joining, aggregating, reshaping), and load results into different destinations. The library emphasizes composability: you build pipelines by chaining method calls, making complex transformations readable and maintainable.
The package works across Python 2.7 and Python 3.6 through 3.13. With no runtime dependencies, it installs cleanly and integrates easily into existing projects. It is actively maintained with recent releases and a stable community, making it suitable for ETL workflows where you need flexibility without the overhead of heavier frameworks.
Use it for:
- Build data pipelines that read from files, filter and reshape rows, then write to a database
- Join and aggregate data from multiple sources for reporting or analytics
- Clean and normalize tabular data before feeding it into downstream workflows
- Extract and transform subsets of large tables without loading everything into memory
- Automate recurring data import and transformation tasks in batch jobs
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
petl extracts, transforms, and loads tables of data using a declarative, composable API that works with multiple data sources and formats.
Yes. petl is a solid, actively maintained library with zero dependencies, permissive licensing, and no known vulnerabilities. It fills a niche for straightforward ETL tasks, data cleaning, and pipeline automation. Install it if you need composable, readable data transformations without framework overhead.
Install
petl on PyPI
pip
pip install petluv
uv add petlpoetry
poetry add petlInstalling petl
Before you install
Low install friction with no runtime dependencies. Actively maintained with a recent release 9 days ago and steady community engagement (1315 GitHub stars).
License in practice
MIT License permits unrestricted use, modification, and distribution in both open-source and commercial projects with minimal restrictions.
Quickstart
pip install petl
import petl as etl
table = [{'id': 1, 'name': 'Alice'}, {'id': 2, 'name': 'Bob'}]
result = etl.wrap(table).cut('name').convert('name', str.upper)
Verify before relying
- Whether the package supports streaming or lazy evaluation for very large datasets
- Performance characteristics and typical use-case boundaries
- Complete list of supported data sources and formats beyond those in the excerpt
Package facts
| License | MIT License (permissive) |
| Python support | supports the current Python release (!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,>=2.7) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 9 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,157,811/month — #4,289 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: petl-1.7.23-py3-none-any.whl
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
tableauhyperapiAutomate creation, reading, and modification of…
permissive · top 5,000 on PyPI
isbnlibisbnlib validates, cleans, transforms, and…
copyleft · top 15,000 on PyPI
dltdlt automates extraction, schema inference, and…
permissive · top 5,000 on PyPI
dbt-coredbt-core transforms raw data in a warehouse…
permissive · top 1,000 on PyPI
pandaspandas provides fast, flexible data structures…
permissive · top 100 on PyPI
pyvrlExposes Vector's VRL (Vector Remap Language) to…
permissive · top 15,000 on PyPI
camelot-pyExtracts tables from PDFs into pandas…
permissive · top 5,000 on PyPI
intakeIntake provides a declarative data catalog…
permissive · top 5,000 on PyPI
frictionlessFrictionless provides a unified Python…
permissive · top 5,000 on PyPI
tabula-pyExtracts tables from PDF files and converts…
permissive · top 5,000 on PyPI