Skip to main content

xlspy — Excel reports, made with Python

Excel reports. Python simplicity.

Turn Python data into Excel workbooks — from everyday reports to large exports.

Read and write XLSB and XLSX, bring your pandas or polars DataFrames, and refresh existing XLSM templates while preserving their macros. Style the result with charts, tables, formatting, and cell notes — all from Python.

Get started · Usage guide · Examples · Benchmarks

Built for speed

2.5 million cells. Ready in seconds.

XLSB with C acceleration Windows WSL2
Write 1.46 s 1.17 s
Read 0.60 s 0.43 s

C acceleration delivered over 10× faster XLSB reads than xlspy's pure-Python fallback in both environments. Figures are medians of three runs on a 50,000 × 50 dataset (Windows: Python 3.14.6; WSL2: Python 3.14.4). See the full comparisons, hardware, and methodology →

Made for the work behind the workbook

Your workflow What xlspy brings
Export large datasets XLSB and XLSX output from a generator or database cursor, with bounded memory via useSharedStrings=False, and C acceleration for supported read and write paths. A failed export publishes no partial workbook (failure handling).
Deliver polished reports Cell styles, number formats, formulas, dropdown validation, hyperlinks, images, print setup, charts (column, bar, line, area, pie, doughnut, scatter, stacked), tables, and conditional formatting. Both XLSX and XLSB support them; see the feature support table.
Work with DataFrames Export pandas or polars data directly to either format.
Refresh a familiar template Replace data in XLSB, XLSX, or XLSM while keeping workbook structure, styles, and unrelated sheets.
Connect a data pipeline Read rows as a generator and stream updates from a database cursor.

The core library has no required Python package dependencies. Add pandas or polars support when you need it. Microsoft Excel is not required for the core read and write APIs.

Quick start

Requires Python 3.12 or newer.

pip install xlspy

Create a report with a styled header and formatted values:

from xlspy import F, Style, XlsxWriter

with XlsxWriter("sales.xlsx") as workbook:
    workbook.add_sheet("Sales")
    workbook.write_sheet(
        [
            ["Product", "Revenue"],
            ["Coffee", (12500, F.THOUSANDS_SEP)],
            ["Tea", (8400, F.THOUSANDS_SEP)],
        ],
        header_style=Style(bold=True, fill="#183C52", font_color="#FFFFFF"),
    )

For binary Excel output, use XlsbWriter and a .xlsb filename with the same API. Explore formatting, charts, and tables when your report needs more detail.

Bring your data. Keep your workflow.

Already using pandas or polars? Export with to_xlsx(df, "report.xlsx") or to_xlsb(df, "report.xlsb"). See DataFrame examples →

Have an Excel template? Refresh its data with XlsxUpdater, XlsbUpdater, or XlsmUpdater. XLSM updates preserve the existing VBA project. Update a workbook →

Need to read the results? Use ExcelReader for XLSB and XLSX, with the same API for both formats. Read a workbook →

Explore further

Resource What you will find
Usage guide Detailed examples, API options, and format support limits.
Runnable examples Scripts for reports, DataFrames, and workbook updates.
Benchmarks Read and write comparisons, dataset details, and reproduction commands.
Validation Windows and WSL2 test results, compatibility checks, and known limitations.
Test suite How to run tests and measure coverage.
Changelog Releases, improvements, and fixes.

MIT licensed · PyPI · Source and issues

Metadata

Release files for xlspy 0.9.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xlspy 0.9.0
File Size Uploaded Provenance
xlspy-0.9.0.tar.gz 397.1 kB With provenance Details

Built distributions (wheels)

Table of built distributions (wheels) for xlspy 0.9.0
File
xlspy-0.9.0-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
xlspy-0.9.0-cp314-cp314-musllinux_1_2_x86_64.whl CPython 3.14 CPython 3.14 Linux musl 1.2+ x86-64 Details
xlspy-0.9.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
xlspy-0.9.0-cp314-cp314-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 macOS 11.0+ ARM64 Details
xlspy-0.9.0-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
xlspy-0.9.0-cp313-cp313-musllinux_1_2_x86_64.whl CPython 3.13 CPython 3.13 Linux musl 1.2+ x86-64 Details
xlspy-0.9.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
xlspy-0.9.0-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details
xlspy-0.9.0-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
xlspy-0.9.0-cp312-cp312-musllinux_1_2_x86_64.whl CPython 3.12 CPython 3.12 Linux musl 1.2+ x86-64 Details
xlspy-0.9.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
xlspy-0.9.0-cp312-cp312-macosx_11_0_arm64.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64 Details

Total release size: 4.5 MB

Release files / xlspy-0.9.0.tar.gz

Download URL xlspy-0.9.0.tar.gz
Size 397.1 kB
Tags Source
SHA-256 checksum
How to use checksums
ebeefaa8925a2eeffd021affbb2fb97799756ccf15b025ebb5139477aa713175
BLAKE2b-256 checksum
How to use checksums
9efb49df1d854d5e621e77bc434f62c4f5de4c6f3bf87b12f0ea5cbca1c6dd96
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp314-cp314-win_amd64.whl

Download URL xlspy-0.9.0-cp314-cp314-win_amd64.whl
Size 298.9 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
822bfcf57d194e782103afdf09c6f1769f5703510c8d3ffb3578cc6689ef5cb7
BLAKE2b-256 checksum
How to use checksums
cb43ddf45317cba62787417f814ddb7310b216f4d176f341f9638378db97ae5f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp314-cp314-musllinux_1_2_x86_64.whl

Download URL xlspy-0.9.0-cp314-cp314-musllinux_1_2_x86_64.whl
Size 389.6 kB
Tags CPython 3.14 Linux musl 1.2+ x86-64
SHA-256 checksum
How to use checksums
a07fb3d6b7297466bb9718e707ac47129cc4000b5bf213e62a359e3a6c6cd56b
BLAKE2b-256 checksum
How to use checksums
46b98ebd63722e860232aa8dc3d7f7cc8b24814636bdc64db019ad755fd4c72a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL xlspy-0.9.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 391.5 kB
Tags CPython 3.14 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
15deed2b7c06b4fdcc1dba4ed806a9197f7160523ea0593275d69842f590f5f6
BLAKE2b-256 checksum
How to use checksums
b8f5508d51f851552858c970a0a34d8a7c986b45d1fd8d45f50a75beb062ac23
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp314-cp314-macosx_11_0_arm64.whl

Download URL xlspy-0.9.0-cp314-cp314-macosx_11_0_arm64.whl
Size 297.2 kB
Tags CPython 3.14 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
6045270ddb95dfea903172eba06ceee9f8949610d9ba53f4cb66c243c76f842c
BLAKE2b-256 checksum
How to use checksums
43053d33d4dc0ef41659f240e6197887f0f70615c22b5379e00d0b4f226252ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp313-cp313-win_amd64.whl

Download URL xlspy-0.9.0-cp313-cp313-win_amd64.whl
Size 297.8 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
3cbf8abd6e8f049b31f5c08937d1c99e5a01617ed3a21618ad9b6e32c21d3c20
BLAKE2b-256 checksum
How to use checksums
758cb7a8bdcafdf98b770a4fd663562056c6782928700591154256d240394947
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp313-cp313-musllinux_1_2_x86_64.whl

Download URL xlspy-0.9.0-cp313-cp313-musllinux_1_2_x86_64.whl
Size 389.7 kB
Tags CPython 3.13 Linux musl 1.2+ x86-64
SHA-256 checksum
How to use checksums
134bd07809ff7d10f71781f14fda96a6a82ebc24750edfd292720c5a5a07cdff
BLAKE2b-256 checksum
How to use checksums
e2540e734d1819f33d60859a5c1f8349b18b78cc99a3f19e34c97437b7027eb6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL xlspy-0.9.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 391.6 kB
Tags CPython 3.13 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
d0c49c41766c1e09b5ae183358fd587f974a1093572ee659e60b32f72bdc6a8f
BLAKE2b-256 checksum
How to use checksums
f89131680ddecaf804d0f5f1344788d8c27412c76faf422723d0073bf250754a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp313-cp313-macosx_11_0_arm64.whl

Download URL xlspy-0.9.0-cp313-cp313-macosx_11_0_arm64.whl
Size 297.2 kB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
92fada8dc5165ce975d41ebd451ee50e6b8cdb8bf10ba85e2f3fb5ed2b4e3455
BLAKE2b-256 checksum
How to use checksums
d9c554e3a18205d32bf6df8c125c671defd3c41c78ba2132b569230266ea419c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp312-cp312-win_amd64.whl

Download URL xlspy-0.9.0-cp312-cp312-win_amd64.whl
Size 297.8 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
37a9b319fa4d2331e4aa16af27dd2771a227c8d308e4bb1cec1ec17ad3c6876f
BLAKE2b-256 checksum
How to use checksums
683f9e36d5f7d9a7d3459a598409272a126ae2c7e0757f8cf1794da9ffb8ec8b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp312-cp312-musllinux_1_2_x86_64.whl

Download URL xlspy-0.9.0-cp312-cp312-musllinux_1_2_x86_64.whl
Size 389.8 kB
Tags CPython 3.12 Linux musl 1.2+ x86-64
SHA-256 checksum
How to use checksums
9f437e43b8a7127608db1e9167674713981c820568417786778fd0765089dcac
BLAKE2b-256 checksum
How to use checksums
f4947bce971850efae01a7ec87f4960eac051fa624472e941a689fd828546295
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL xlspy-0.9.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 391.6 kB
Tags CPython 3.12 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
571e118103cda50c718bfea1397236043108cf241519675137a72ff59cffc682
BLAKE2b-256 checksum
How to use checksums
912e0b4e9684453cd45d45aa7aa13992ab45831fdb7f82bea78ea95860c996d6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / xlspy-0.9.0-cp312-cp312-macosx_11_0_arm64.whl

Download URL xlspy-0.9.0-cp312-cp312-macosx_11_0_arm64.whl
Size 297.2 kB
Tags CPython 3.12 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
b557a082be2347b8c81300eb7bb27de3ea6c2b087a735c21653fbdb85e45ae6e
BLAKE2b-256 checksum
How to use checksums
dacecefe4036a8415ccb787b04e7eed61ca07a2fff4597c45b1a413a47109211
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Security for xlspy 0.9.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 13 files in this release have been uploaded with provenance metadata.

Select from 13 files

Attestation for xlspy-0.9.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page