# Change file permissions for files created in Nextcloud

**URL:** <https://help.nextcloud.com/t/change-file-permissions-for-files-created-in-nextcloud/48347>\
**Category:** ℹ️ Support\
**Created:** [February 26, 2019, 8:43am UTC](https://help.nextcloud.com/t/change-file-permissions-for-files-created-in-nextcloud/48347 "2019-02-26T08:43:56Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![gas85](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gas85/32/7772_2.png) [@gas85](https://help.nextcloud.com/u/gas85)\
**Post date:** [February 26, 2019, 12:03pm UTC](https://help.nextcloud.com/t/change-file-permissions-for-files-created-in-nextcloud/48347/2 "2019-02-26T12:03:58Z")

</div>

Direct access is not the way how NC is working. You should use WebDav (what is more slower as SMB). Otherwise you can set some local folder as External Storage and give NC access to it --\> [https://docs.nextcloud.com/server/15/admin\_manual/configuration\_files/external\_storage\_configuration\_gui.html#adding-files-to-external-storages](https://docs.nextcloud.com/server/15/admin_manual/configuration_files/external_storage_configuration_gui.html#adding-files-to-external-storages)

Do not forget that you have to re scan changes periodically (otherwise folder will be re scanned only by direct web access). Command to do this is: `sudo -u www-data php occ files:scan --all`

This command will rescan **whole** NC installation together with all internal and external files, so I wrote a script to do external storage rescan only:

> <https://github.com/GAS85/nextcloud_scripts/blob/master/nextcloud-file-sync.sh>

Read more about this script under this tread: [Automate OCC Filescan](https://help.nextcloud.com/t/automate-occ-filescan/35282/4?u=gas85)

---

_[View the full topic](https://help.nextcloud.com/t/change-file-permissions-for-files-created-in-nextcloud/48347)._
