# Can I safely delete the content of /data/ directory (files and images)?

**URL:** <https://forum.mattermost.com/t/can-i-safely-delete-the-content-of-data-directory-files-and-images/3903>\
**Category:** Troubleshooting\
**Created:** [September 28, 2017, 12:27pm UTC](https://forum.mattermost.com/t/can-i-safely-delete-the-content-of-data-directory-files-and-images/3903 "2017-09-28T12:27:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![GuiGuiSoft](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/guiguisoft/32/1597_2.png) [@GuiGuiSoft](https://forum.mattermost.com/u/GuiGuiSoft)\
**Post date:** [September 28, 2017, 12:27pm UTC](https://forum.mattermost.com/t/can-i-safely-delete-the-content-of-data-directory-files-and-images/3903/1 "2017-09-28T12:27:14Z")

</div>

Hello,

I am using a local storage directory for files and images. **Can I safely delete all files in it ?**  
Of course they won’t be accessible through the Mattermost interface (404-error-like ?).  
My question is : **are they any other side effects ?**

Note that I am not asking for a feature _(I already voted for this on uservoice a long time ago)_. I am looking for a workaround because the feature is not implemented today.  
I totally understand that Mattermost developers don’t want to implement the feature (because of a business plan, because of other priorities, lack of time…). But I don’t want to add “unlimited” local storage or pay for amazon service for “old files forgotten by all” 😛

Thank you for your feedbacks.  
Regards.

---

<div class="post-metadata">

**Author:** ![MusikPolice](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/musikpolice/32/1451_2.png) [@MusikPolice](https://forum.mattermost.com/u/MusikPolice)\
**Post date:** [October 2, 2017, 12:42pm UTC](https://forum.mattermost.com/t/can-i-safely-delete-the-content-of-data-directory-files-and-images/3903/2 "2017-10-02T12:42:53Z")

</div>

Mattermost stores custom branding, custom emoji, and user profile images in the `FileSettings.Directory` location, in addition to files that have been uploaded by users. If your team doesn’t use any of these features, you _should_ be ok, but I want to stress that deleting the contents of this directory is not recommended, and would encourage you to take a backup of the directory before proceeding, just in case you need to recover the data that you have deleted.

---

<div class="post-metadata">

**Author:** ![alimirza\_nva](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@alimirza\_nva](https://forum.mattermost.com/u/alimirza_nva)\
**Post date:** [May 1, 2018, 3:19pm UTC](https://forum.mattermost.com/t/can-i-safely-delete-the-content-of-data-directory-files-and-images/3903/3 "2018-05-01T15:19:17Z")

</div>

@GuiGuiSoft Hey - did you try deleting the user uploaded files manually? If yes, did anything break? Any learning that you might be able to transfer over to us?

@MusikPolice we are in the same boat here. For Mattermost team edition, it seems that the only way of using Mattermost long term is to keep expanding storage space on the implementation server to accommodate both old and new files that users upload. A permanent delete option for old files is needed ASAP. This is one of the biggest issues with Mattermost team edition right now. And before you ask, have already upvoted relevant feature requests on user voice 🙂
