.xls vs .xlsx — What Changed and Why It Matters

February 15, 2026 · 8 min read

If you've been using Excel for more than a decade, you've seen both file extensions. You probably know .xlsx is "the newer one." But what actually changed between .xls and .xlsx — and more importantly, what breaks when you convert? This guide covers every meaningful difference, including the one that silently destroys VBA macros if you migrate wrong.

In this article

  1. A brief history of Excel file formats
  2. How the file structures differ
  3. Row, column, and sheet limits
  4. The macro problem: .xlsx vs .xlsm
  5. Formula and function compatibility
  6. When each format makes sense
  7. How to migrate correctly
  8. FAQ

A Brief History of Excel File Formats

Microsoft Excel has used the .xls extension since Excel 2.0 in 1987. The underlying format is called BIFF (Binary Interchange File Format), and it evolved through eight versions — BIFF2 through BIFF8 — with Excel 97's BIFF8 being the version most people mean when they say ".xls." For roughly two decades, .xls was Excel.

In 2007, Microsoft shipped the Office Open XML standard, and with it came .xlsx. The format change was significant: instead of a proprietary binary blob, .xlsx is a ZIP archive containing XML files. Open one with any ZIP tool and you'll find folders and human-readable XML describing every sheet, cell, style, and chart relationship.

The "x" in .xlsx stands for XML. The "m" in .xlsm (Excel Macro-Enabled Workbook) stands for macro. That distinction — between .xlsx and .xlsm — is where most migrations go wrong.

How the File Structures Differ

The architectural difference between .xls and .xlsx isn't just cosmetic. It has practical consequences for everything from file size to third-party compatibility.

Attribute.xls (BIFF8).xlsx (Open XML)
IntroducedExcel 97 (1997)Excel 2007 (2007)
Underlying formatBinary (proprietary)ZIP archive of XML files
StandardMicrosoft-proprietaryECMA-376 / ISO/IEC 29500
Human-readableNoYes (unzip and inspect)
Typical file sizeLargerSmaller (compressed)
Third-party supportReverse-engineeredOpen specification
Can store VBA macrosYesNo — use .xlsm
Max rows per sheet65,5361,048,576
Max columns per sheet256 (IV)16,384 (XFD)

The ZIP-based structure of .xlsx has real benefits: files are typically 20–50% smaller than equivalent .xls files (XML compresses well), and because the format is an open standard, non-Microsoft tools — LibreOffice, Google Sheets, Python's openpyxl — support it natively without reverse-engineering binary blobs.

Row, Column, and Sheet Limits

The most visible difference for data-heavy workbooks is the row limit increase.

Row Limit

The BIFF8 format uses a 16-bit integer for row addressing, which caps at 216 = 65,536 rows. Open XML uses a 20-bit row index, giving 220 = 1,048,576 rows. That's 16 times more rows per sheet.

For most users, 65,536 rows is plenty — typical business spreadsheets rarely approach it. But if you're using Excel as a data dump for transaction logs, sensor readings, or large exports, you've probably hit row 65,536 and watched Excel silently truncate the rest. .xlsx eliminates this ceiling for most practical purposes.

Column Limit

.xls supports 256 columns (A through IV). .xlsx supports 16,384 columns (A through XFD). This matters for wide pivot tables, survey data exports, and cross-tab analyses with many time periods.

Sheet Limit

Both formats support up to 255 worksheets per workbook in practice (limited by available memory). This is not a meaningful difference between the formats.

Not sure what's in your .xls files?

LegacyLeaps's free scan shows you exactly what will change — row counts, macro presence, formula compatibility — before you migrate a single file.

Try the Free Scan

The Macro Problem: .xlsx vs .xlsm

This is the most important difference, and the one most likely to cause a real problem during migration.

The Open XML specification deliberately excludes VBA macro code from the .xlsx format. Microsoft made this decision when designing the format: .xlsx is a clean, macro-free document format. If you want macros, you use .xlsm.

The silent data loss scenario: You open an .xls file in Excel 2016 or later. You press Save As. You select .xlsx. Excel asks if you want to save in a "macro-free" format. You click "Yes, keep this format" because you want .xlsx. Excel saves the file. Your VBA modules are gone — no undo, no recovery, no warning that it happened.

What .xlsm Is and When to Use It

An .xlsm file is structurally identical to .xlsx — same ZIP/XML format, same Open XML standard, same row limits. The only difference is that .xlsm includes a vbaProject.bin file inside the ZIP archive, which stores the VBA project (modules, forms, and references).

If your .xls file contains any VBA code — a single macro, a Workbook_Open event, a custom function — you must save as .xlsm, not .xlsx. Saving as .xlsx will strip the code.

How to check before you migrate: In Excel, press Alt+F11 to open the VBA editor. If you see any modules listed in the Project Explorer on the left, you have VBA code. Close the editor, and save as .xlsm.

For Batch Migration

When migrating many files, manually checking each one for macros isn't realistic. LegacyLeaps's free scan audits every file in your batch and automatically identifies which ones contain VBA — so macro files get saved as .xlsm and clean files get saved as .xlsx with no manual intervention required.

Formula and Function Compatibility

The vast majority of Excel formulas work identically across .xls and .xlsx. Basic arithmetic, text functions, lookup functions, date math — all of it transfers cleanly.

There are two categories of exceptions to be aware of:

Legacy Statistical Functions (Replaced in Excel 2010)

When Microsoft introduced Excel 2010, they replaced several statistical functions with improved versions that calculate more accurately. The old function names still work as compatibility aliases, but if your .xls files use them, you should know what changed:

Old Function (.xls era)New Function (Excel 2010+)What Changed
STDEVSTDEV.SClearer naming; same calculation
STDEVPSTDEV.PClearer naming; same calculation
RANKRANK.EQ / RANK.AVGTie-handling made explicit
PERCENTILEPERCENTILE.INC / PERCENTILE.EXCInclusive/exclusive boundary made explicit
QUARTILEQUARTILE.INC / QUARTILE.EXCInclusive/exclusive boundary made explicit
BETADISTBETA.DISTAdditional parameters added
NORMDISTNORM.DISTRenamed for consistency

The old names still work in modern Excel — they're not removed, just deprecated. Your formulas won't break. But if you're doing critical statistical work, it's worth reviewing which version's behavior you're relying on.

Array Formulas (Dynamic Array Functions)

Excel 365 introduced dynamic array functions (FILTER, SORT, UNIQUE, XLOOKUP) that don't exist in Excel 2003 or earlier. .xls files obviously can't contain them. This only matters if you're migrating in the opposite direction — from .xlsx back to .xls — which you shouldn't be doing anyway.

When Each Format Makes Sense

Use .xls when...

Outside of these narrow scenarios, there is no reason to stay on .xls in 2026.

Use .xlsx when...

Use .xlsm when...

How to Migrate Correctly

The right approach depends on how many files you're moving and whether they contain macros.

Single file, no macros

  1. Open the .xls file in Excel
  2. File → Save As → select .xlsx
  3. Confirm when Excel warns about macro-free format (if no macros, this is safe)
  4. Open the new .xlsx file and spot-check formulas and formatting

Single file with macros

  1. Press Alt+F11 to confirm which modules/forms exist
  2. File → Save As → select .xlsm (not .xlsx)
  3. Open the new .xlsm and run key macros to confirm they execute
  4. Check for PtrSafe errors if macros use Win32 API declarations (see our VBA troubleshooting guide)

Batch migration

For organizations migrating dozens or hundreds of files, manual conversion isn't practical. A PowerShell script can automate basic conversion, but it won't handle macro detection, PtrSafe updates, or formula validation. LegacyLeaps handles all of this automatically — scan first to see what you're working with, then migrate with one click per batch.

For a complete walkthrough of batch migration including a PowerShell script for the simpler cases, see the Complete Guide to Legacy Excel Migration.

Ready to migrate?

Download LegacyLeaps and scan your files for free. See exactly what needs to be converted — macros, formula issues, row counts — before you spend a penny.

Download Free Scanner

Frequently Asked Questions

What is the difference between .xls and .xlsx?

.xls uses Microsoft's binary BIFF format (Excel 97–2003). .xlsx uses the Open XML format introduced in Excel 2007. The main differences: .xlsx supports 1,048,576 rows vs 65,536 in .xls; .xlsx uses a ZIP-based open standard; .xlsx cannot store VBA macros (use .xlsm instead); and .xlsx files are generally smaller and faster to open.

Can .xlsx files contain macros?

No. .xlsx files cannot store VBA macros. If your .xls file contains macros, you must save as .xlsm (Excel Macro-Enabled Workbook) to preserve them. Saving as .xlsx silently strips all VBA code.

Is .xlsx better than .xls?

.xlsx is the modern standard and better for most purposes: larger row limits, smaller file sizes, better compatibility with non-Microsoft tools, and based on an open standard. The only reason to stay on .xls is compatibility with Excel 97–2003, which is rarely a real constraint in 2026.

Will my formulas still work after converting from .xls to .xlsx?

Most formulas work identically. A small number of legacy statistical and math functions were replaced with more accurate versions in Excel 2010+. If your .xls uses STDEV, RANK, PERCENTILE, or similar functions, verify results after conversion. LegacyLeaps's free scan flags these before you migrate.

What is the row limit in .xls vs .xlsx?

.xls supports a maximum of 65,536 rows and 256 columns per sheet. .xlsx supports 1,048,576 rows and 16,384 columns per sheet — 16x more rows and 64x more columns.

Get tips like this in your inbox

Practical fixes for legacy Excel and Access problems. No spam.

← Back to all posts