.xls

What is a .xls file?

Microsoft Excel 97-2003 Spreadsheet · Document · Microsoft · 1997

XLS is the classic Microsoft Excel spreadsheet format used until 2007, before XLSX. It is a binary OLE2 compound file holding cells, formulas, formatting and charts. Excel still opens it.

Category
Document
Type
Binary
Is a .xls file safe to open? Mostly safe, but .xls can contain macros. Keep macros disabled unless you trust the source; malicious spreadsheet macros are a known attack route.

What is a .xls file used for?

An .xls file stores a workbook of sheets, formulas and formatting in the OLE2 compound-file structure it shares with old Word and PowerPoint. Excel 2007 replaced it with the XML-based XLSX.

XLS is limited to 65,536 rows per sheet, one reason the newer XLSX (over a million rows) took over. Excel, LibreOffice Calc and Google Sheets all still read .xls.

What opens a .xls file?

The .xls format opens in the following apps, grouped by operating system. If one app does not work, try another from the same list.

Windows

  • Microsoft Excel
  • LibreOffice Calc
  • WPS Office

macOS

  • Microsoft Excel
  • Numbers
  • LibreOffice Calc

Linux

  • LibreOffice Calc
  • OnlyOffice

Web

  • Google Sheets
  • Microsoft 365 for the web

Open a .xls file step by step

  1. Confirm the file really is a .xls. Drop it into the WhatFileType identifier, which reads its signature in your browser without uploading anything.
  2. On Windows, open it with Microsoft Excel or LibreOffice Calc.
  3. On Mac, use Microsoft Excel or Numbers.
  4. On Linux, try LibreOffice Calc or OnlyOffice.
  5. Still stuck? Convert the .xls to xlsx, which opens more widely.

Why can't I open my .xls file?

Almost always because no installed app understands XLS. Install one of the apps above, or convert the file to a format your existing software already reads. If double-clicking opens the wrong program instead of nothing at all, the file association is set to the wrong app rather than the file being broken.

The other possibility is that the file is not really a .xls at all. Drop it into the file identifier to check it by its bytes instead of its name. Nothing is uploaded.

How to convert a .xls file

You can convert a .xls file to xlsx, csv, ods, pdf using a conversion tool or the export menu of an app that opens it.

What is the .xls file signature (magic bytes)?

A .xls file starts with the hex bytes D0 CF 11 E0 A1 B1 1A E1. Programs identify XLS by those bytes, not by the filename, so a renamed file still gives itself away.

These are the documented signatures for XLS. For a full breakdown, see the OLE2 Compound File file signature page.

Documented magic-byte signatures for the .xls format
Hex signatureOffsetASCIINote
D0 CF 11 E0 A1 B1 1A E10-OLE2 compound file

See the full magic-numbers reference for every format.

Frequently asked questions

What is a .xls file?

XLS is the classic Microsoft Excel spreadsheet format used until 2007, before XLSX. It is a binary OLE2 compound file holding cells, formulas, formatting and charts. Excel still opens it.

What is the difference between XLS and XLSX?

XLS is the old binary format (Excel 97-2003), capped at 65,536 rows. XLSX, from Excel 2007, is a ZIP of XML with over a million rows and smaller files.

How do I open an .xls file?

Excel, LibreOffice Calc, Google Sheets and Numbers all open .xls, and can convert it to XLSX or CSV.

Why does Excel warn about macros in an .xls?

Old spreadsheets can embed VBA macros that run code. Excel disables them by default; only enable macros for files you trust.

Related formats

Sources

Details on this page were checked against authoritative references. How sources are ranked and what is deliberately left out is set out in the methodology.