Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in


How to save a selection as individual file in Excel?

When we deal with a long worksheet, we may want to save only a selected range instead of a whole workbook as a new Excel file, such as sending different selections of a worksheet to different persons. We will introduce methods to save selections in a worksheet as individual Excel files.

Save selections as individual Excel files with copying and pasting

Save selections as individual Excel files with VB Macro

Save Selections as individual Excel files with Kutools for Excel

Excel Productivity Tools

Office Tab: Bring powerful tabs to Office (include Excel), just like Chrome, Safari, Firefox and Internet Explorer. Save you half the time, and reduce thousands of mouse clicks for you. 30-day Unlimited Free Trial

Kutools for Excel: Save 70% of your time and solve 80% Excel problems for you. 300+ advanced features designed for 1500+ work scenario, make Excel much easy and increase productivity immediately.60-day Unlimited Free Trial

arrow blue right bubble Save selections as individual files with copying and pasting

The most common method is to copy the selection that you want to save as an individual file in Excel, create a new workbook, and paste the copied selection on it, then save it.

However, you may lose some format styles in the selection during copying and pasting, such as row height, etc.

arrow blue right bubble Save selections as individual files with VB Macro

Using Macro is an easy way to save the selections as individual files without copying and pasting to a new workbook.

1. Hold down the ALT + F11 keys to open the Microsoft Visual Basic for Applications window.

2. Click Insert > Moudle, and paste the following code into the Moudle Window.

VBA: export range to Excel file

Sub ExportRangetoExcel()
'Update 20130916
Dim wb As Workbook
Dim saveFile As String
Dim WorkRng As Range
Dim address As String
Dim defult As Integer
On Error Resume Next
xTitleId = "KutoolsforExcel"
Set WorkRng = Application.Selection
Set WorkRng = Application.InputBox("Range", xTitleId, WorkRng.address, Type:=8)
Application.ScreenUpdating = False
Application.DisplayAlerts = False
defult = Application.SheetsInNewWorkbook
Application.SheetsInNewWorkbook = 1
Set wb = Application.Workbooks.Add
Application.SheetsInNewWorkbook = defult
address = Replace(WorkRng.address, ":", "-")
address = Replace(address, "$", "")
address = Replace(address, ".", "")
saveFile = Application.GetSaveAsFilename(InitialFileName:=address, fileFilter:="Excel Workbooks (*.xlsx),*.xlsx")
wb.SaveAs Filename:=saveFile
Application.CutCopyMode = False
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub

3. Then press F5 key to execute the operation, and a prompt box will pop out to remind you select a range that you want to save as individual Excel file. See screenshot:


4. Then click OK, and specify a folder to locate this new file and then enter a name for your file in the Save As dialog box, see screenshot:


5. And then click Save button, the selected range has been saved as a new Excel workbook.

Using Macro may be a little hard for starter of Microsoft Excel, and we will introduce another easy and convenient way provided with Kutools for Excel.

arrow blue right bubble Save Selections as individual files with Kutools for Excel

Kutools for Excel's Export Range to File tool can help us conveniently save selections as individual files quickly.

Kutools for Excel includes more than 300 handy Excel tools. Free to try with no limitation in 30 days. Get it Now.

If you have installed Kutools for Excel, please do as this:

1. Click Enterprise > Import / Export > Export Range to File, see screenshot:


2. In the Export Range to File dialog box, click the doc-data-to-csv-6button to select the range that you want to save it as an individual file, and then check Excel workbook option in File format section, at last, you can check the workbook options as you need.


3. Click OK, then it will pop up a Select a name and location for the exported range dialog box, enter a name for this new file, and select a folder where you will save it in. And then click Save button.


1. The Export Range to File tool of Kutools for Excel can save all formatting in the selections.

2. Kutools for Excel's Export Range to File tool makes it possible to easily export a range of date to a file, either an Excel workbook, a CSV, a simple HTML or all formatting HTML.

3. If you check Open the file after export option in the dialog box, the new file will be launched automatically after exporting it successfully.

To know more about this feature, please click Export Range to File.

arrow blue right bubbleRelated Articles

Excel Productivity Tools

Ribbon of Excel (with Kutools for Excel installed)

300+ Advanced Features Increase Your Productivity by 70%, and Help You To Stand Out From Crowd!

Would you like to complete your daily work quickly and perfectly? Kutools For Excel brings 300+ cool and powerful advanced features (Combine workbooks, sum by color, split cell contents, convert date, and so on...) for 1500+ work scenarios, helps you solve 80% Excel problems.

  •  Deal with all complicated tasks in seconds, help to enhance your work ability, get success from the fierce competition, and never worry about being fired.
  •  Save a lot of work time, leave much time for you to love and care the family and enjoy a comfortable life now.
  •  Reduce thousands of keyboard and mouse clicks every day, relieve your tired eyes and hands, and give you a healthy body.
  •  Become an Excel expert in 3 minutes, and get admiring glance from your colleagues or friends.
  •  No longer need to remember any painful formulas and VBA codes, have a relaxing and pleasant mind, give you a thrill you've never had before.
  •  Spend only $39, but worth than $4000 training of others. Being used by 110,000 elites and 300+ well-known companies.
  •  60-day unlimited free trial. 60-day money back guarantee. Free upgrade and support for 2 years. Buy once, use forever.
  •  Change the way you work now, and give you a better life immediately!

Office Tab Brings Efficient And Handy Tabs to Office (include Excel), Just Like Chrome, Firefox, And New IE

  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Open and create documents in new tabs of same window, rather than in new windows.
  • Help you work faster and easily stand out from the crowd! One second to switch between dozens of open documents!
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    Medhavi · 1 years ago

    Liked the VBA option. Is there a way to retain formulas in new file? The data in new file is automatically pasted s 'values' and does not have the formulas.
  • To post as a guest, your comment is unpublished.
    Kanariya · 3 years ago
    Do you know how I can do this on a default custom template? I have a lot of data in one book/sheet that I have to save only a selection to a new file. Option 2 works great. But, I need to have some information on the top for each new file I make (Copying and pasting is very tedious so I am looking for a quicker and more effective option). So would it be possible to first use the file with lots of data and select certain cells to save ON the default custom template I made, specifically underneath the header of the default template (the template is integrated into Excel to automatically open when I open Excel). Please help, thanks!!
  • To post as a guest, your comment is unpublished.
    Yan · 4 years ago
    i have tried different things to make it copy+paste value, i dont know where i go wrong.

    How do i change the VBA: export range to Excel file to just copy paste value? TIA
  • To post as a guest, your comment is unpublished.
    D. Smith · 5 years ago
    This VB macro is great! However, I was wondering if there was a way to keep the source formatting when the selected range gets saved to a new workbook. Thanks!
  • To post as a guest, your comment is unpublished.
    Brett Murphy · 5 years ago

    I am use the above VB macro, and works great. The only thing is that the range i select has a results from a formula and when i open the text file i get #REF.
    Could you please help out.

    • To post as a guest, your comment is unpublished.
      Hanan · 5 months ago
      Double click on #REF cell and will get it right