--- id: xlsx2html version: "0.6.4" license: MIT license_treatment: permissive maintenance: active --- # xlsx2html — A simple export from xlsx format to html tables with keep cell formatting License: permissive · Maintenance: active · Downloads: 194.1K/mo ## What it is and what it does xlsx2html is a lightweight Python converter that reads Excel workbooks and outputs them as HTML tables. It wraps openpyxl for reading .xlsx files and uses babel for locale-aware formatting of numbers and dates. The package is designed for straightforward export scenarios where you need to turn spreadsheet data into web-viewable HTML while maintaining basic cell formatting. The library supports multiple input/output modes: reading from file paths, working with file-like objects in memory, or running as a command-line tool. It's in Alpha status and actively maintained, supporting Python 3.6 through 3.14 and PyPy. With no known vulnerabilities and permissive MIT licensing, it's a low-risk choice for simple xlsx-to-html pipelines. Use it for: - Export financial reports or data tables from Excel to embed in web dashboards or email templates. - Batch convert spreadsheet archives to HTML for archival or documentation purposes. - Generate HTML previews of uploaded Excel files in web applications without server-side rendering. - Automate spreadsheet-to-web workflows where cell formatting (alignment, number display) matters. - Convert locale-specific spreadsheets (e.g., European number formats) to correctly formatted HTML tables. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Converts Excel spreadsheets (.xlsx files) to HTML tables while preserving cell formatting, with support for locale-specific number and date rendering. Yes, if you need straightforward xlsx-to-HTML conversion with basic formatting preservation. Low install friction, active maintenance, MIT license, and no vulnerabilities make it safe. Best suited for simple export tasks; verify first whether its formatting support (colors, fonts, merged cells) meets your specific needs before relying on it for complex spreadsheets. ## Install pip install xlsx2html uv add xlsx2html poetry add xlsx2html ## Installing xlsx2html Before you install: Low friction: pure Python wheel with four common dependencies (six, openpyxl, babel, packaging). Last release 172 days ago with active repository maintenance and 71 GitHub stars. License in practice: MIT license permits commercial and private use with minimal restrictions—include a copy of the license and you're clear. Quickstart: pip install xlsx2html from xlsx2html import xlsx2html # Convert to stream out_stream = xlsx2html('path/to/example.xlsx') out_stream.seek(0) html_output = out_stream.read() # Or write directly to file xlsx2html('path/to/example.xlsx', 'path/to/output.html') Verify before relying: - Whether cell formatting preservation includes colors, fonts, borders, or only basic alignment and number formats. - Performance characteristics when processing large spreadsheets (row/column limits, memory usage). - Support for merged cells, formulas, or other advanced Excel features. - Locale parameter behavior and which locales are supported beyond 'en'. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 194.1K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags xlsx to html converter, excel spreadsheet html export, xlsx table conversion, preserve excel formatting html, excel to html with styles, batch convert xlsx files, excel-conversion, data-export [View on SkillFed](https://skillfed.io/packages/xlsx2html) · [View on PyPI](https://pypi.org/project/xlsx2html/)