4

As you know, OneDrive lets you to backup PC folders called 'Desktop', 'Documents' and 'Pictures' under Important PC Folders section.

enter image description here

I want to backup all these folders except one of these folders contain few sub-folders which I don't want to sync. How do I exclude these sub-folders?

Meraj al Maksud
  • 190
  • 2
  • 15
  • Simple answer? Move them somewhere else. – Señor CMasMas Jun 10 '20 at 16:19
  • Clever one. But you know that I am not intending to do that. Otherwise, this question would not be posted. Can you please help me find if there is any function that enables me to exclude the sub-folders without removing from the selected folders? – Meraj al Maksud Jun 11 '20 at 06:03
  • 1
    Sorry Meraj.. ;) I could not help myself.. but seriously.. OneDrive [doesn't support this](https://answers.microsoft.com/en-us/msoffice/forum/all/stopping-onedrive-from-syncing-specific-files/e5f3fd2e-6ec4-403b-9435-1ada19026919) .. perhaps you can come up with a more creative solution.. move the folder.. sync.. move it back? .. sorry.. – Señor CMasMas Jun 11 '20 at 17:06

1 Answers1

3

If you still need the answer, I finally managed to find sort of a workaround.

Instructions:

  1. If the folder already exists, copy the insides somewhere else temporarily.
  2. Delete the original folder in your documents folder.
  3. Create a new, empty one, with the desired name.
  4. Let it sync.
  5. In the onedrive client, go to settings -> Choose folders, and uncheck the folder. It will disappear from you local documents folder (that's why we backed up earlier), but stay online.
  6. Close onedrive completely. Pausing is not enough.
  7. Create the local folder again, with the same name.
  8. Open onedrive again.

If done correctly, onedrive will flag the folder as unsyncable, because of a version mismatch.

  1. Copy back the files you backed up.

Instructions with images

  • 1
    Please tell me this is not the only option. This is so lame. – David Sopko Mar 08 '21 at 21:33
  • 3
    So far, this seems like the only option as the tracking of files (on desktop or otherwise) is about pulling the files down from OneDrive, more than it is pushing the files up to OneDrive. So when you choose the folders, it's about not displaying the OneDrive documents locally. --- I agree, this is a horrible feature. It would be better to have a local ignore, similar to a `.gitignore` file, which allows it to be retained and used locally, without committing the files to the OneDrive repo/storage. – Mike Aug 15 '21 at 17:36
  • I'm not sure if I did something wrong, but after following the instructions I got the sync error, then a few seconds later, the error disappears and the folder syncs again. So this method might not work anymore – The Bic Pen Nov 21 '21 at 04:23
  • 1
    @TheBicPen Try creating a file (like an empty text file) in the folder you created in step 7, before doing step 8 –  Nov 24 '21 at 02:17