Approdo is in build and not yet available. Register your interest →
Approdo › Guides › Fix long paths

How to fix “path too long” in a SharePoint migration

Updated October 2026 · 7 min read

Short answer: SharePoint in Microsoft 365 does not accept a file path, file name included, of more than 400 characters. Fix it by shortening or flattening the deep folders before upload. Doing it by hand is slow and risks breaking links. Approdo is being built to find every over‑length path, propose shorter names, apply the plan you approve and log every change.

What the limit actually is

Microsoft's SharePoint limits page gives the path limit as 400 characters for the entire decoded file path, including the file name. The folder path and the file name are counted together, after decoding.

It is the path at the destination that counts: Microsoft's page on Migration Manager lists files whose destination path is longer than 400 characters among those that are not migrated.

Why it works in Windows but fails in SharePoint

Modern Windows happily opens very deep paths — with the \\?\ prefix or long‑paths enabled, it goes well beyond the old 260‑character MAX_PATH. So the files sit there perfectly readable on the file server. SharePoint, though, holds the whole file path to 400 characters, so the identical deep path is refused at upload. That mismatch is why "it's fine on the server" and "it won't migrate" are both true at once.

How to find your long paths

Before you can fix them you need to know where they are. You can script this with PowerShell (enumerating the tree and measuring each full path), but on a large share that's slow and gives you a raw list with no plan. A good migration assessment should surface the longest paths, how many exceed the limit, and by how much — so you know the size of the job before you start.

The manual fixes — and why they hurt

On a real file server this is hours to days of careful, error‑prone work — and it's exactly the kind of task that gets rushed at the end of a migration window.

How Approdo will fix long paths

Shorten, not flatten

Truncating shortens over‑long names; flattening removes an unnecessary folder tier by lifting its contents up. Flattening removes folders and cannot be undone, so Approdo will not flatten. It will propose shorter names only, and show you each one before anything is renamed.

Keeping track of links

Because every rename is logged, Approdo will keep a map of old → new names — useful for updating shortcuts and for the audit trail.

Approdo is coming soon

Approdo's free assessment lists every over‑length path and shows exactly how it'll fix them.

Register your interest →

FAQ

What is the SharePoint path length limit?

Microsoft's published limit is 400 characters for the entire decoded file path, including the file name. Microsoft's page on Migration Manager lists files whose destination path is longer than 400 characters among those that are not migrated.

Can I just enable long paths in Windows to fix it?

That helps Windows handle the files, but it doesn't help SharePoint — SharePoint's 400‑character limit on the file path still applies. You have to shorten or flatten the structure before upload.

Will fixing paths break my links?

It can if done carelessly. Approdo will log every rename as an old → new map, so you can update references, and nothing is renamed until you approve the plan.