How to convert files .xls to .xlsx?

Chua, Ee Yuan 0 Reputation points
2026-08-17T06:55:56.4566667+00:00

How to convert files .xls to .xlsx? I have more than 100 files need to convert to .xlsx files. Please help on this. Thanks.

Microsoft 365 and Office | Other
0 comments No comments

3 answers

Sort by: Most helpful
  1. Ramesh Srinivasan 88,880 Reputation points Independent Advisor
    2026-08-17T07:51:45.4733333+00:00

    Hi Chua, Ee Yuan,

    You can use the following VBScript to bulk convert .xls files in a folder to .xlsx.

    As I'm unable to upload the script file in this forum, I've uploaded it to a third-party portal.

    Download convert.vbs.txt from https://gofile.io/d/18zsv74H (which I uploaded now).

    Save convert.vbs.txt to your desktop. Rename it to convert.vbs (i.e., remove the .txt extension).


    How to use the script

    Drag the folder (containing the .xls files) and drop it onto the script file `convert.vbs".

    The script will automatically convert the .xls files in the target folder to .xlsx files.


    Standard Disclaimer: There is a link to a non-Microsoft website. The page appears to provide accurate, safe information. Watch out for ads on the site that may advertise products frequently classified as PUPs (Potentially Unwanted Products). Thoroughly research any product advertised on the site before you decide to download and install it.

    (VBScript files have text-based content. If you want to check its contents before executing it, you can open it using Notepad.)

    Was this answer helpful?

    0 comments No comments

  2. Senthil kumar 2,665 Reputation points
    2026-08-17T07:08:24.4933333+00:00

    Hi @Chua, Ee Yuan

    its possible from powershell command and vba code. here i attached the powershell comand.

    $source = "C:\XLS_Files"
    $target = "C:\XLSX_Output"
    
    $excel = New-Object -ComObject Excel.Application
    $excel.Visible = $false
    $excel.DisplayAlerts = $false
    
    Get-ChildItem -Path $source -Filter *.xls | ForEach-Object {
        $file = $_.FullName
        $workbook = $excel.Workbooks.Open($file)
    
        $newFile = Join-Path $target ($_.BaseName + ".xlsx")
        $workbook.SaveAs($newFile, 51)   # 51 = xlOpenXMLWorkbook (.xlsx)
    
        $workbook.Close()
    }
    
    $excel.Quit()
    
    
    

    Thanks.

    Was this answer helpful?

    0 comments No comments

  3. Chua, Ee Yuan 0 Reputation points
    2026-08-17T06:57:39.2733333+00:00

    Can we convert 100 files in one time from .xls to .xlsx ?

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.