Read data out of legacy .xls files exported from old accounting or banking software.
Convert an .xls file to JSON or CSV from the command line without writing code.
Add .xls file support to a Node.js or browser app without adding heavy dependencies.
| zanlucathiago/xls-reader | 1521620063/vomishield | agentfm-ai/agent-fm | |
|---|---|---|---|
| Stars | 21 | 21 | 21 |
| Language | TypeScript | TypeScript | TypeScript |
| Setup difficulty | easy | moderate | easy |
| Complexity | 2/5 | 2/5 | 2/5 |
| Audience | developer | general | developer |
Figures from each repo's GitHub metadata at analysis time.
xls-reader is a small JavaScript and TypeScript library that reads old style .xls spreadsheet files, the format used by Excel 97 through 2003, technically called BIFF8. It works in both Node.js and web browsers, and it has zero external dependencies, meaning it does not pull in any other packages to do its job. The project exists because most modern tools, like ExcelJS, only understand the newer .xlsx format, and the one library that used to handle old .xls files, SheetJS, stopped publishing updates to the npm registry. That makes it hard for other tools like npm audit to check it for security problems. xls-reader fills that gap with a small, MIT licensed package that is still actively published to npm. Using it is straightforward. You call readXls on the raw bytes of an .xls file and get back a workbook object containing one or more sheets, each with rows of cells. There is also a readFirstSheet shortcut for files with just one sheet you care about, and a sheetToObjects function that turns rows into JavaScript objects using the first row as column names. A sheetToCsv function converts a sheet into a CSV string, following standard CSV quoting rules, with dates converted to ISO format. For people who do not want to write any code, the package also includes a command line tool. Running npx xls-reader on a file prints its contents as JSON, and flags let you pick a specific sheet, export as CSV instead, or compact the output onto a single line. The library handles the details of the old Excel format for you: numbers, dates, blank cells, and Excel error values like #DIV/0! all come back as sensible JavaScript types. It also reports whether each sheet in a workbook is visible or hidden. This tool is best suited for developers who need to read legacy spreadsheet files inside a Node or browser application, particularly anyone maintaining older business systems that still produce .xls exports, such as banking or accounting software.
A small zero-dependency library that reads old .xls spreadsheet files in Node or the browser, replacing the abandoned SheetJS npm package.
Mainly TypeScript. The stack also includes TypeScript, JavaScript, Node.js.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Don't trust strangers blindly. Verify against the repo.