I am going to get batches of 200+ Excel files with a blank password, one just needs to press enter when asked for the password. The system I am loading these files into cannot handle password protected Excel sheets. Is there a command line or other solution where I can just open those Excel sheets with the known blank password and then re-save them without a password?

This password is to open the file.

I followed the recommendation in STTR's answer and used DocRecrypt. I am no longer prompted for a password for these files when opening them. Awesome.

  • 1
    Just to clarify, is this an password to open the file or for document protection? And what version are you dealing with? – CharlieRB Mar 27 '13 at 13:31
  • The last paragraph that you keep putting back should not be part of the question. It should be a comment on the answer. – fixer1234 Dec 3 '15 at 21:07

Test DocRecrypt.

Microsoft Office 2013 DocRecrypt Tool

To remove the password from a file, use this code:

DocRecrypt –i lockedfile 

To remove the password and assign a new password of 12345, use this code:

DocRecrypt –p 12345 –i lockedfile 

To remove the password, create a new file, and assign a new password of 12345 to that file, use this code:

DocRecrypt –p 12345 –i lockedfile -o newfile 

way 2:


Set objExcel = CreateObject("Excel.Application")
objExcel.Visible = TRUE 
objExcel.DisplayAlerts = FALSE
Path1="D:\VBS\VBS85 Excel Unprotect password\Book1.xlsx"
Path2="D:\VBS\VBS85 Excel Unprotect password\Book2.xlsx"
Set objWorkbook = objExcel.Workbooks.Open(Path1,,,," ")
objWorkbook.Password = ""
objWorkbook.SaveAs Path2
  • STTR, what Excel file versions does this tool work with (.xml, .xlsx, .xls, etc.)? – chuff Mar 27 '13 at 12:36
  • @chuff Testing provides the most reliable answers. If I was sure that it works for all versions of Office files, and I would say Use. But I say Test). – STTR Mar 27 '13 at 12:49
  • The OP asks how to remove the password, not change it, so the file does not prompt for a password. Does this DocRecrypt Tool do that for them? – CharlieRB Mar 27 '13 at 13:38
  • @CharlieRB Thx, fixed. – STTR Mar 27 '13 at 13:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.