How to Auto Backup Excel File: 2 Easy Methods

Method 1 – Use Excel’s General Options to Auto Backup an Excel File

Step 1: Create an Auto Backup File

  • Click the File tab.

Handy Approaches to Auto Backup Excel File

  • Select Save As.
  • Click-double the This PC.

Handy Approaches to Auto Backup Excel File

  • Click the Tools.
  • From the list, choose the General Options.

Handy Approaches to Auto Backup Excel File

  • Click to mark checked the box named Always create backup.
  • Press Enter.

Handy Approaches to Auto Backup Excel File

  • Click Save.
  • Choose Yes to Replace the existing file.

Handy Approaches to Auto Backup Excel File

  • The name “Backup of” and the current worksheet name will be produced, as seen in the figure below.

Handy Approaches to Auto Backup Excel File

Step 2: Update Any Data in the Main worksheet

  • Highlight the two following cells first.
  • Save the file by clicking the Save icon or pressing Ctrl + S.

Handy Approaches to Auto Backup Excel File

  • Color another cell or make any changes as you wish and save the file.

Handy Approaches to Auto Backup Excel File

Step 3: Open the Backup File

  • Open the backup (Backup of Backup Excel) file.

Handy Approaches to Auto Backup Excel File

  • Show the result from the last edit before the previous saving.

Handy Approaches to Auto Backup Excel File

Notes. Whenever you save a modification to the current spreadsheet, the Excel backup file is changed to match the state of the spreadsheet before the latest save. The .XLK extension is used for the Excel backup file, which is saved in the same directory as the source. It’s worth noting that the first time you save, the files will be identical. But when you change and save the file for the third time, it will show the results from the second save. In general, the backup file is one version behind the current version.

Method 2 – Run a VBA Code to Auto Backup an Excel File

Step 1: Create a Folder

  • Create a folder (AutoBack) with three files: one folder (Final Backup), a VBA worksheet for writing VBA codes (Auto Backup Creator), and your current worksheet (Main Worksheet).

Handy Approaches to Auto Backup Excel File

Step 2: Create a Module

  • Open the Auto Backup Creator file.
  • Press Alt + F11 to open the VBA Macro.
  • Click the Insert tab.
  • Select the Module option to create a new Module.

Sample Data

Step 3: Run the VBA codes

  • Paste the following VBA codes.
  • Press  F5  to run the program.
Sub AutoBackup()
Application.DisplayAlerts = False
Application.ScreenUpdating = False
'Insert the file path/location of your current workbook
Workbooks.Open Filename:="C:\Users\Admin\Desktop\Files\AutoBack\Main Worksheet.xlsx" _
, UpdateLinks:=3
'Insert the file path/location of your Backup file workbook
Workbooks("Main Worksheet.xlsx").SaveAs Filename:="C:\Users\Admin\Desktop\Files\AutoBack\Final Backup\Main Worksheet " & "(AutoBack) " & Format(Now(), "(yyyy-mm-dd hhmm)") & ".xlsx"
ActiveWindow.Close
Workbooks("Auto Backup Creator.xlsm").Close SaveChanges:=True
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub

Sample Data

Step 4: Check the Backup File

  • Go to the Final Backup folder.

Sample Data

  • Get a created auto-backup file (Main Worksheet (AutoBack)) containing the date and time.

Sample Data

  • Click the Main Worksheet (AutoBack) file and see the backup results from your previous savings.

Sample Data


Download Practice Workbook

Download this practice workbook to exercise while you are reading this article.


Related Articles


<< Go Back to Recover Excel File | Excel Files | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Bhubon Costa
Bhubon Costa

Bhubon Costa, B.Sc. in Naval Architecture & Marine Engineering from Bangladesh University of Engineering & Technology, has worked with the ExcelDemy since 2021. Currently, he has been working as a reviewer. Notably, he has written over 90 articles and led several VBA content development teams. He has a great passion for the fields of data analytics and data science. His areas of expertise include Excel VBA, Power Query, Pivot Table, Power BI, MySQL, PostgreSQL, machine learning, and Python... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo