Say you’re moving two department shares, a 6-file Policies folder and a 4-file Marketing share, into one SharePoint library. Put both in a CSV file and let the SharePoint Migration Tool run them together.
In this tutorial, we’ll migrate file shares to SharePoint in bulk: plan the move, build the CSV (or JSON) file, run it in SPMT, check what landed where, and see when Migration Manager fits better.
The sample file shares we’ll use
Both shares go to the Migration Demo library on /sites/SPGuides. If you still need a target, first create a document library in SharePoint Online. See the SharePoint tutorials hub too.
| Source share | Contents | Target folder |
|---|---|---|
| SPGuides Policies | HR (3 files), Finance (2 files), Company Holidays 2026.docx = 6 files | Migration Demo/Policies |
| Marketing Share | Campaigns (3 files), Brand Assets (1 file) = 4 files | Migration Demo/Marketing |
For one folder, the SPMT wizard is enough: Single file share source, pick the folder, site and library, then Start. My post How to Use the SharePoint Migration Tool (SPMT) Step by Step covers every screen.
Plan the file share move first
Before you write the CSV, plan these:
- Inventory: list each share, its owner, size and target library.
- Clean up: delete duplicates and old junk.
- Restructure: flatten deep trees. See this SharePoint folder structure that scales helps here.
- Permissions: set up site groups first, following SharePoint permissions best practices.
Then check the limits that trip up old file servers:
| Limit | What Microsoft documents |
|---|---|
| Path length | The full decoded path, including the file name, can’t exceed 400 characters |
| Invalid characters | " * : < > ? / \ |, plus leading or trailing spaces |
| Blocked names | .lock, CON, PRN, AUX, NUL, COM0-COM9, LPT0-LPT9, desktop.ini, _vti_, names starting with ~$ |
| File size | 250 GB per file |
Pro Tip: Turn on Replace invalid filename characters in SPMT settings. With it off, those files are skipped, and a package with more than 100 errors gets blocked.
Method 1: Bulk migration with a CSV file (Recommended)
Use this for more than one share. Each row is one task, with no header row. Here’s the file I ran:
C:\Shares\SPGuides Policies,,,https://yourtenant.sharepoint.com/sites/SPGuides,Migration Demo,Policies
C:\Shares\Marketing Share,,,https://yourtenant.sharepoint.com/sites/SPGuides,Migration Demo,Marketing
How does this work?
| # | Column | For a file share |
|---|---|---|
| 1 | Source | Required: the folder path |
| 2 | Source DocLib | Leave empty |
| 3 | Source SubFolder | Leave empty |
| 4 | Target Web | Required: the site URL |
| 5 | Target DocLib | Required: the library name, here Migration Demo |
| 6 | Target SubFolder | Optional: empty means the library root |
That’s why three commas follow the path. Microsoft Learn’s format page actually lists 8 columns (the last two are hub site columns for SharePoint site migrations) and says all columns must be present. My 6-column file worked in SPMT 4.3.130.12, but to match the documented format, add two empty trailing commas:
C:\Shares\SPGuides Policies,,,https://yourtenant.sharepoint.com/sites/SPGuides,Migration Demo,Policies,,
Now run it. In SPMT, select File share > Add new migration and choose Bulk migration using JSON or CSV file.

Enter the CSV path in File path.

Review migration lists one row per task:

Select Next, then Start. Both tasks ran in parallel.

After about 1 minute, the Migration complete dialog showed 10 out of 10 items and 296.20 KB out of 296.20 KB.

Per task, Policies moved 6 of 6 items (183.99 KB) and Marketing 4 of 4 (112.21 KB).

So here’s the catch: with a target subfolder, the source folder’s contents land in it. I got Policies/HR, not Policies/SPGuides Policies/HR.
Method 2: Use a JSON file instead
JSON suits task lists built by a script. Here’s the first task in Microsoft’s format:
{
"Tasks": [
{
"SourcePath": "C:\\Shares\\SPGuides Policies",
"TargetPath": "https://yourtenant.sharepoint.com/sites/SPGuides",
"TargetList": "Migration Demo",
"TargetListRelativePath": "Policies"
}
]
}
How does this work?
Only SourcePath and TargetPath are required; TargetListRelativePath is the subfolder.
Check the results
File share > View migrations showed both as Completed.

View reports opens a WF_ folder with Log and Report subfolders. Compare file counts in the library and check site permissions in SharePoint Online. To reorganize later, move folders in SharePoint Online.
Which method should you use?
| Situation | Use |
|---|---|
| One folder, one-time move | SPMT single file share source |
| A few shares from one PC or server | SPMT bulk CSV |
| Task list built by a script | SPMT bulk JSON |
| Many file servers, large volume, central tracking | Migration Manager |
Migration Manager lives in the SharePoint admin center and sends tasks to agents on several servers. It needs SharePoint admin rights and SMB 2.0+ sources. Moving home drives? Read the difference between SharePoint and OneDrive first.
Things to Keep in Mind
- CSV picked as a folder: a CSV path under Single file share source shows the error below. Choose the bulk option instead.
- Header row: don’t add one; every line is a task.
- Throttling: run big batches on evenings or weekends.
- Library design: follow these document library best practices.

Once the files are in SharePoint, these guides help you organize and secure them:
Frequently Asked Questions
Does the SPMT CSV file need a header row?
No. Every line is read as a task, one source and destination per row.
Can I migrate file share permissions with SPMT?
Yes. Turn on Preserve file share permissions.
Why did my files land without the source folder name?
With a target subfolder, SPMT copies the folder’s contents into it. Leave it empty for the library root.
Where is Microsoft’s CSV and JSON format documented?
In Format your JSON or CSV file for data content migration on Microsoft Learn.
When should I use Migration Manager instead of SPMT?
For many file servers with agents and central reporting. See Migrate your file shares with Migration Manager.

Hey! I’m Bijay Kumar, founder of SPGuides.com and a Microsoft Business Applications MVP (Power Automate, Power Apps). I launched this site in 2020 because I truly enjoy working with SharePoint, Power Platform, and SharePoint Framework (SPFx), and wanted to share that passion through step-by-step tutorials, guides, and training videos. My mission is to help you learn these technologies so you can utilize SharePoint, enhance productivity, and potentially build business solutions along the way.