pandas-read-xml
A tool to read XML files as pandas dataframes.
What it is and what it does
pandas_read_xml bridges the gap between XML's hierarchical structure and pandas' tabular format. It reads XML files and converts them into DataFrames by letting you specify the path to the root tag containing your data, similar to how pd.read_csv() works. The package also provides utilities to flatten nested structures and automatically separate what appear to be distinct relational tables from a single XML source.
The core use case is extracting structured data from XML without manual parsing. It handles common XML quirks—like inconsistent nesting across files from the same schema—through methods like auto_flatten() and auto_separate_tables(). However, the package has been archived since 2021 and receives no maintenance, so it is best suited for projects with stable XML schemas and no need for ongoing support.
Use it for:
- Extract tabular data from XML exports of relational databases where the schema is known but nesting is inconsistent.
- Convert XML API responses into pandas DataFrames for analysis without writing custom parsing code.
- Flatten deeply nested XML structures into separate normalized tables for data warehousing or ETL pipelines.
- Quickly prototype data pipelines that ingest XML files when pandas' native XML support is insufficient.
- Separate mixed-type nested elements in XML (lists vs. scalars) into distinct DataFrames automatically.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Converts XML files into pandas DataFrames, with tools to flatten nested structures and separate relational data from hierarchical XML sources.
Yes, if you have a specific XML-to-DataFrame conversion task and the current API matches your needs. The low install friction and permissive license make it a reasonable choice for one-off scripts or prototypes. No, if you need ongoing maintenance, bug fixes, or compatibility with future pandas versions—the package is archived and unmaintained since 2021. Consider alternatives or implement custom parsing if your XML handling is mission-critical.
Install
pandas-read-xml on PyPI
pip
pip install pandas-read-xmluv
uv add pandas-read-xmlpoetry
poetry add pandas-read-xmlInstalling pandas-read-xml
Before you install
Low friction installation as a pure-Python wheel. However, the package is abandoned as of 2021 and has not been maintained for over three years; the repository is archived. Use only if the current API meets your needs without expectation of bug fixes or updates.
License in practice
MIT license permits commercial and private use with minimal restrictions, making it safe from a licensing standpoint for most projects.
Quickstart
pip install pandas_read_xml
import pandas_read_xml as pdx
df = pdx.read_xml('file.xml', ['root', 'child', 'target_tag'])
Requires Python 3.6 or later; XML file path and correct tag hierarchy must be known in advance.
Verify before relying
- Whether the package handles modern XML schemas or edge cases introduced in recent pandas versions
- Compatibility with current versions of runtime dependencies (pyarrow, pandas, xmltodict, requests, urllib3)
- Performance characteristics on large or deeply nested XML files
Package facts
| License | not declared (permissive) |
| Python support | supports the current Python release (>=3.6) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 7 — pyarrow, pandas, xmltodict, requests, zipfile36, distlib, urllib3 |
| Maintenance | abandoned — 1,954 days since the last release |
| Last repo commit | (repository archived) |
| First released | |
| Downloads | 495,268/month — #6,342 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pandas_read_xml-0.3.1-py3-none-any.whl
Tags
More Markup packages
PyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
markdown-it-pyA Python markdown parser that converts markdown…
permissive · top 100 on PyPI
beautifulsoup4Beautiful Soup parses HTML and XML documents…
permissive · top 100 on PyPI
et-xmlfileet_xmlfile writes large XML files with minimal…
permissive · top 1,000 on PyPI
tomlkitParses and edits TOML files while preserving…
permissive · top 1,000 on PyPI
docstring-parserParses Python docstrings in ReST, Google,…
permissive · top 1,000 on PyPI
gspread-dataframeConverts between Google Sheets worksheets and…
permissive · top 5,000 on PyPI
gspread-pandasBridges Google Sheets and pandas DataFrames,…
permissive · top 15,000 on PyPI
json-flattenerConverts nested JSON/YAML objects into flat…
permissive · top 15,000 on PyPI
flatten-jsonConverts nested JSON objects into flat…
permissive · top 5,000 on PyPI
pandas_accessReads MS Access database files (.mdb) into…
permissive · top 15,000 on PyPI
pandas-tdPandas-TD connects pandas DataFrames to…
permissive · top 15,000 on PyPI
sas7bdatReads SAS7BDAT files (SAS statistical software…
permissive · top 15,000 on PyPI
npTDMSRead and write TDMS files (LabVIEW data format)…
copyleft · top 15,000 on PyPI
gtfparseParses GTF (gene transfer format) files into…
permissive · top 15,000 on PyPI
pandavroReads and writes Apache Avro files to and from…
permissive · top 15,000 on PyPI