How to set a file or folder to be ignored

Updated Nov 07, 2023

Ignored files are files in the Dropbox folder on your computer that aren’t stored on the Dropbox server. This means they can’t be accessed on dropbox.com, and won’t sync to your Dropbox account. Setting files and folders to be ignored requires knowledge of the PowerShell (Windows) or Terminal (Mac and Linux) applications.

Tip: If you want to manage which files sync to your computer without using the PowerShell or Terminal applications, you can use selective sync or make files and folders online-only or available offline.

 

Set a file or folder to be ignored by Dropbox

To ignore a file or folder, follow the instructions for your operating system below.

  1. Open the PowerShell application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you’d like to ignore.

Set-Content -Path 'C:\Users\yourname\Dropbox(Personal)\YourFileName.pdf' -Stream com.dropbox.ignored -Value 1

3. Press enter on your keyboard.

The icon beside your file or folder will change to a gray minus sign indicating that it has been ignored.

The latest Dropbox for macOS update utilizes Apple’s updated File Provider API to more deeply integrate with macOS. This update will change which code to use when setting files or folders to be ignored. 
Find out which version of Dropbox for macOS you’re running.

If you’re running macOS 12.3 or earlier:

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you’d like to ignore. 

xattr -w com.dropbox.ignored 1 /Users/yourname/Dropbox\ \(Personal\)/YourFileName.pdf

3. Press enter on your keyboard. 

 

The icon beside your file or folder will change to a gray minus sign indicating that it has been ignored.

 

If you’re running macOS 12.5 or later and have the updated version of Dropbox for macOS:

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you’d like to ignore. 

xattr -d 'com.apple.fileprovider.ignore#P' /Users/yourname/Library/CloudStorage/Dropbox-Personal/YourFileName.pdf

3. Press enter on your keyboard. 
4. Additionally, type this code below, replacing the file/folder path placeholder         with the file/folder path you no longer want to ignore.

xattr -d 'com.apple.fileprovider.ignore#P' /Users/yourname/Library/CloudStorage/Dropbox-Personal/YourFileName.pdf

5. Press enter on your keyboard.

The icon beside your file or folder will change to a cloud with a diagonal line through it indicating that it has been ignored.

Learn more about macOS sync icons and what they mean.

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you’d like to ignore.

attr -s com.dropbox.ignored -V 1 /Users/yourname/Dropbox\ \(Personal\)/YourFileName.pdf

3. Press enter on your keyboard. 

The icon beside your file or folder will change to a gray minus sign indicating that it has been ignored.

 

Set a file or folder to no longer be ignored by Dropbox

If you no longer want a file or folder to be ignored, follow the instructions for your operating system below.

  1. Open the PowerShell application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you no longer want to ignore. 

Clear-Content -Path 'C:\Users\yourname\Dropbox(Personal)\YourFileName.pdf' -Stream com.dropbox.ignored

        3. Press enter on your keyboard.

 

If you’re running macOS 12.3 or earlier:

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you no longer want to ignore.

xattr -d com.dropbox.ignored /Users/yourname/Dropbox\ \(Personal\)/YourFileName.pdf

        3. Press enter on your keyboard. 

 

The icon beside your file or folder will change to a green check mark indicating that it is no longer ignored. 

 

If you’re running macOS 12.5 or later and have the updated version of Dropbox for macOS:

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you no longer want to ignore.

xattr -d com.dropbox.ignored /Users/yourname/Library/CloudStorage/Dropbox-Personal/YourFileName.pdf

        3. Press enter on your keyboard. 
        4. Additionally, type this code below, replacing the file/folder path placeholder         with the file/folder path you no longer want to ignore.

xattr -d 'com.apple.fileprovider.ignore#P' /Users/yourname/Library/CloudStorage/Dropbox-Personal/YourFileName.pdf

        5. Press enter on your keyboard.

The crossed-out cloud icon will no longer be next to this file/folder, indicating that it is no longer ignored.

Note: If you’ve set your files to online-only, the icon may also change to an online-only icon or a mixed state icon depending on your settings. 

Learn more about macOS sync icons and what they mean.

 

  1. Open the Terminal application on your computer.
  2. Type the code below, replacing the file/folder path placeholder with the file/folder path you no longer want to ignore.

attr -r com.dropbox.ignored /Users/yourname/Dropbox\ \(Personal\)/YourFileName.pdf

        3. Press enter on your keyboard. 

The icon beside your file or folder will change to a green check mark indicating that it is no longer ignored.

 

 

FAQs about ignored files

What happens after I set a file or folder to be ignored by Dropbox?

Once ignored, the file or folder stays in your Dropbox folder on your computer’s hard drive. However, it will be deleted from the Dropbox server and your other devices. You also won’t be able to access it on dropbox.com and it won’t sync to your Dropbox account. You can choose to sync that file or folder back to dropbox.com at any time.

Will a file within an ignored folder also be ignored?

If you move a file or folder to an ignored folder, it will cause that file or folder to be ignored as well. If you move that file or folder out of the ignored folder, it will no longer be ignored.

Can you sync changes made to a shared file or folder that is ignored by Dropbox?

If you ignore a shared file or folder, any edits made to it on your computer (or to the shared version online) won’t sync with each other. 

If you set it not to be ignored anymore, Dropbox will merge the previously ignored file or folder with the shared file or folder online, if possible. If not, Dropbox will keep both versions and label one as a conflicted copy so no edits are lost.

Will the commands to ignore files and folders work on my operating system? 

If you’re using Windows, Linux, or macOS earlier than 12.5 and have moved the Dropbox folder to a location other than the default one, the commands above won't work. You’ll need to update it manually.

 

Was this article helpful?

We’re sorry to hear that.
Let us know how we can improve.

Thanks for your feedback!
Let us know how this article helped.

Thanks for your feedback!

Community answers