Get all your news in one place.
100’s of premium titles.
One app.
Start reading
PC Gamer
PC Gamer
Wes Fenlon

Here's how to permanently wipe OneDrive folders from your PC if they keep recreating themselves

OneDrive crossed out

There aren't many things in life I regret more than letting Windows install OneDrive. Honestly, I don't remember if it even gave me an option, but I assume that at some point when updating Windows 10 Microsoft snuck it in and I didn't find the buried checkbox I needed to nip it right in the bud. So I let OneDrive in, it took over my Documents and Photos folders, promptly filled up its cloud storage, and started hounding me to buy more storage space. "Immediately making your product hateable" doesn't strike me as the best strategy, but maybe my lack of vision in this area is why I don't run a trillion-dollar company. Anyway: I got fed up, uninstalled OneDrive, and assumed that would be the end of it.

It was not the end of it.

Steve Ballmer's ghost has been haunting me through an undead OneDrive folder ever since. Even though I told OneDrive to stop syncing all my folders and then uninstalled it, somewhere in the bowels of Windows a remnant remained. When I installed new programs, they'd often default to storing their config files in C:\Users\[myname]\OneDrive\Documents. Even though I had deleted that folder. They just kept recreating it! 

I can't say I keep my PC perfectly organized—my Downloads folder is a mess of years worth of animated gifs and installers—but I at least like to know that when I open up my Documents folder, it's all of my documents, not Most Of My Documents Except The Ones Created By Programs Installed In The Last Month. The general advice here is to set your Documents folder location in File Explorer, but I'd done that, and it didn't stop the OneDrive folder from being resurrected with every new install.

I scoured the internet looking for a solution for this problem, and most Microsoft help pages and forum discussions I ended up on were dead ends. Finally I found it: the registry entry I needed to modify to banish OneDrive from my PC once and for all. Hopefully this offers someone else out there the same relief it offered me.

How to stop Windows programs from defaulting to a nonexistent OneDrive folder

We're going to do some very light registry editing to fix this annoying problem. Don't worry, it isn't scary: these are clearly marked, easily understandable registry entries we're changing, not arcane blobs of numbers.

1. Press the Windows key and type "Regedit" to search for the Registry Editor. Click it to open it up.

2. Copy/paste this string into the address bar at the top and hit enter: 

Computer\HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders

Once there, you should see a fairly short list of default folder locations. If your system is like mine, most of these entries are in plain English, e.g. "My Music" and "Programs," while a few are longer bits of gibberish in {}. What you want to look at is the Data column, which indicates where Windows is by default directing new programs that want to set up shop in your Documents/Photos/etc. folders. Here I found my culprits. 

(Image credit: Future)

3. The fix is simple. Right-click on each entry in the Name column and hit Modify. Delete "OneDrive\" from the address string and hit OK. Do this for any and all entries where OneDrive shows up. 

(Image credit: Future)

And that's it: you're freed from the OneDrive curse. Breathe deep of that fresh, clean air and enjoy knowing that new programs will put their files just where you want them. 

Sign up to read this article
Read news from 100’s of titles, curated specifically for you.
Already a member? Sign in here
Related Stories
Top stories on inkl right now
One subscription that gives you access to news from hundreds of sites
Already a member? Sign in here
Our Picks
Fourteen days free
Download the app
One app. One membership.
100+ trusted global sources.