← Back
Editing: file_sharing_configuration.html
<!DOCTYPE html> <html class="writer-html5" lang="en" data-content_root="../"> <head> <meta charset="utf-8" /> <meta name="readthedocs-addons-api-version" content="1"><meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>File Sharing — Nextcloud latest Administration Manual latest documentation</title> <link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=b86133f3" /> <link rel="stylesheet" type="text/css" href="../_static/css/theme.css?v=e59714d7" /> <link rel="stylesheet" type="text/css" href="../_static/copybutton.css?v=76b2166b" /> <link rel="stylesheet" type="text/css" href="../_static/custom.css?v=8ff6e0db" /> <link rel="stylesheet" type="text/css" href="../_static/dark_mode_css/general.css?v=c0a7eb24" /> <link rel="stylesheet" type="text/css" href="../_static/dark_mode_css/dark.css?v=70edf1c7" /> <link rel="canonical" href="https://docs.nextcloud.com/server/stable/admin_manual/configuration_files/file_sharing_configuration.html" /> <script src="../_static/jquery.js?v=5d32c60e"></script> <script src="../_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script> <script src="../_static/documentation_options.js?v=a49d5d77"></script> <script src="../_static/doctools.js?v=9bcbadda"></script> <script src="../_static/sphinx_highlight.js?v=dc90522c"></script> <script src="../_static/clipboard.min.js?v=a7894cd8"></script> <script src="../_static/copybutton.js?v=f281be69"></script> <script src="../_static/dark_mode_js/default_light.js?v=c2e647ce"></script> <script src="../_static/dark_mode_js/theme_switcher.js?v=358d3910"></script> <script src="../_static/js/theme.js"></script> <script src="../_static/js/versions.js"></script> <link rel="index" title="Index" href="../genindex.html" /> <link rel="search" title="Search" href="../search.html" /> <link rel="next" title="Configuring Federation Sharing" href="federated_cloud_sharing_configuration.html" /> <link rel="prev" title="File sharing and management" href="index.html" /> </head> <body class="wy-body-for-nav"> <div class="wy-grid-for-nav"> <nav data-toggle="wy-nav-shift" class="wy-nav-side"> <div class="wy-side-scroll"> <div class="wy-side-nav-search" > <a href="../contents.html"> <img src="../_static/logo-white.png" class="logo" alt="Logo"/> </a> <div class="switch-menus"> <div class="version-switch"></div> <div class="language-switch"></div> </div> <div role="search"> <form id="rtd-search-form" class="wy-form" action="../search.html" method="get"> <input type="text" name="q" placeholder="Search docs" aria-label="Search docs" /> <input type="hidden" name="check_keywords" value="yes" /> <input type="hidden" name="area" value="default" /> </form> </div> </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu"> <p class="caption" role="heading"><span class="caption-text">Getting Started</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../index.html">Introduction</a></li> <li class="toctree-l1"><a class="reference internal" href="../release_schedule.html">Maintenance and release schedule</a></li> <li class="toctree-l1"><a class="reference internal" href="../gdpr/index.html">GDPR-compliance</a></li> <li class="toctree-l1"><a class="reference internal" href="../declarations/index.html">Declarations</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Release notes</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../release_notes/index.html">Critical changes</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Installation</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../installation/index.html">Installation and server configuration</a></li> <li class="toctree-l1"><a class="reference internal" href="../configuration_database/index.html">Database configuration</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Configuration</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../configuration_server/index.html">Nextcloud configuration</a></li> <li class="toctree-l1"><a class="reference internal" href="../occ_command.html">Using the occ command</a></li> <li class="toctree-l1"><a class="reference internal" href="../reference/index.html">Reference management</a></li> <li class="toctree-l1"><a class="reference internal" href="../webhook_listeners/index.html">Webhook Listeners</a></li> <li class="toctree-l1"><a class="reference internal" href="../windmill_workflows/index.html">Windmill Workflows</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Files</span></p> <ul class="current"> <li class="toctree-l1 current"><a class="reference internal" href="index.html">File sharing and management</a><ul class="current"> <li class="toctree-l2 current"><a class="current reference internal" href="#">File Sharing</a><ul> <li class="toctree-l3"><a class="reference internal" href="#advanced-settings">Advanced settings</a></li> <li class="toctree-l3"><a class="reference internal" href="#distinguish-between-max-expiration-date-and-default-expiration-date">Distinguish between max expiration date and default expiration date</a></li> <li class="toctree-l3"><a class="reference internal" href="#get-a-notification-before-a-share-expires">Get a notification before a share expires</a></li> <li class="toctree-l3"><a class="reference internal" href="#transferring-files-to-another-user">Transferring files to another user</a></li> <li class="toctree-l3"><a class="reference internal" href="#creating-persistent-file-shares">Creating persistent file Shares</a></li> <li class="toctree-l3"><a class="reference internal" href="#using-file-drop-share-links">Using File Drop Share links</a></li> </ul> </li> <li class="toctree-l2"><a class="reference internal" href="federated_cloud_sharing_configuration.html">Configuring Federation Sharing</a></li> <li class="toctree-l2"><a class="reference internal" href="big_file_upload_configuration.html">Uploading big files > 512MB</a></li> <li class="toctree-l2"><a class="reference internal" href="default_files_configuration.html">Providing default files</a></li> <li class="toctree-l2"><a class="reference internal" href="primary_storage.html">Configuring Object Storage as Primary Storage</a></li> <li class="toctree-l2"><a class="reference internal" href="external_storage_configuration_gui.html">Configuring External Storage (GUI)</a></li> <li class="toctree-l2"><a class="reference internal" href="external_storage/auth_mechanisms.html">External Storage authentication mechanisms</a></li> <li class="toctree-l2"><a class="reference internal" href="encryption_configuration.html">Server-side encryption configuration</a></li> <li class="toctree-l2"><a class="reference internal" href="encryption_details.html">Server-side encryption details</a></li> <li class="toctree-l2"><a class="reference internal" href="encryption_migration.html">Server-side encryption migration</a></li> <li class="toctree-l2"><a class="reference internal" href="files_locking_transactional.html">Transactional file locking</a></li> <li class="toctree-l2"><a class="reference internal" href="previews_configuration.html">Previews configuration</a></li> <li class="toctree-l2"><a class="reference internal" href="file_versioning.html">Controlling file versions and aging</a></li> <li class="toctree-l2"><a class="reference internal" href="trashbin_configuration.html">Deleted Items (trash bin)</a></li> <li class="toctree-l2"><a class="reference internal" href="file_conversion.html">File conversion</a></li> <li class="toctree-l2"><a class="reference internal" href="windows_compatible_filenames.html">Windows compatible filenames</a></li> </ul> </li> <li class="toctree-l1"><a class="reference internal" href="../file_workflows/index.html">Flow</a></li> <li class="toctree-l1"><a class="reference internal" href="../configuration_mimetypes/index.html">Mimetypes management</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Apps</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../apps_management.html">Apps management</a></li> <li class="toctree-l1"><a class="reference internal" href="../exapps_management/index.html">ExApps management</a></li> <li class="toctree-l1"><a class="reference internal" href="../ai/index.html">Artificial Intelligence</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Users</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../configuration_user/index.html">User management</a></li> <li class="toctree-l1"><a class="reference internal" href="../desktop/index.html">Desktop Clients</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Groupware</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../groupware/index.html">Groupware</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Office</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../office/index.html">Office</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Maintenance</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../configuration_monitoring/index.html">Monitoring</a></li> <li class="toctree-l1"><a class="reference internal" href="../maintenance/index.html">Maintenance</a></li> <li class="toctree-l1"><a class="reference internal" href="../issues/index.html">Issues and troubleshooting</a></li> </ul> <p class="caption" role="heading"><span class="caption-text">Links</span></p> <ul> <li class="toctree-l1"><a class="reference external" href="https://help.nextcloud.com/">Community Help Forum</a></li> <li class="toctree-l1"><a class="reference external" href="https://docs.nextcloud.com/">User Manuals</a></li> <li class="toctree-l1"><a class="reference external" href="https://docs.nextcloud.com/">Developer Manuals</a></li> <li class="toctree-l1"><a class="reference external" href="https://nextcloud.com/install/">Download</a></li> <li class="toctree-l1"><a class="reference external" href="https://apps.nextcloud.com">App Store</a></li> <li class="toctree-l1"><a class="reference external" href="https://help.nextcloud.com/t/translation-knowledge-valid-for-the-entire-nextcloud-project-wiki/51550">Translations</a></li> <li class="toctree-l1"><a class="reference external" href="https://github.com/nextcloud/">GitHub</a></li> <li class="toctree-l1"><a class="reference external" href="https://github.com/nextcloud/server/wiki/Maintenance-and-Release-Schedule">Supported versions</a></li> <li class="toctree-l1"><a class="reference external" href="https://nextcloud.com/enterprise/">Nextcloud Enterprise</a></li> <li class="toctree-l1"><a class="reference external" href="https://github.com/nextcloud/server/blob/master/COPYING-README">License</a></li> <li class="toctree-l1"><a class="reference external" href="https://nextcloud.com/">Nextcloud GmbH</a></li> </ul> </div> </div> </nav> <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" > <i data-toggle="wy-nav-top" class="fa fa-bars"></i> <a href="../contents.html">Nextcloud latest Administration Manual</a> </nav> <div class="wy-nav-content"> <div class="rst-content style-external-links"> <div role="navigation" aria-label="Page navigation"> <ul class="wy-breadcrumbs"> <li><a href="../contents.html" class="icon icon-home" aria-label="Home"></a></li> <li class="breadcrumb-item"><a href="index.html">File sharing and management</a></li> <li class="breadcrumb-item active">File Sharing</li> <li class="wy-breadcrumbs-aside"> <a href="https://github.com/nextcloud/documentation/edit/master/admin_manual/configuration_files/file_sharing_configuration.rst" class="fa fa-github"> Edit on GitHub</a> </li> </ul> <hr/> </div> <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article"> <div itemprop="articleBody"> <section id="file-sharing"> <span id="file-sharing-configuration"></span><h1>File Sharing<a class="headerlink" href="#file-sharing" title="Link to this heading"></a></h1> <p>Nextcloud users can share files with their Nextcloud groups and other users on the same Nextcloud server, with Nextcloud users on <a class="reference internal" href="federated_cloud_sharing_configuration.html"><span class="doc">other Nextcloud servers</span></a>, and create public shares for people who are not Nextcloud users. You have control of a number of user permissions on file shares.</p> <p>Configure your sharing policy on your Admin page in the Sharing section.</p> <figure class="align-default"> <img alt="../_images/sharing-files-1.png" src="../_images/sharing-files-1.png" /> </figure> <ul> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">apps</span> <span class="pre">to</span> <span class="pre">use</span> <span class="pre">the</span> <span class="pre">Share</span> <span class="pre">API</span></code> to enable users to share files. If this is not checked, no users can create file shares.</p> <ul> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">resharing</span></code> to enable users to re-share files shared with them.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">sharing</span> <span class="pre">with</span> <span class="pre">groups</span></code> to enable users to share with groups.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Restrict</span> <span class="pre">users</span> <span class="pre">to</span> <span class="pre">only</span> <span class="pre">share</span> <span class="pre">with</span> <span class="pre">users</span> <span class="pre">in</span> <span class="pre">their</span> <span class="pre">groups</span></code> to confine sharing within group memberships. When you check this, you’ll get an optional dropdown list of ignored groups when checking group membership. Type any group name to search for.</p> <ul class="simple"> <li><p>Groups added to <code class="docutils literal notranslate"><span class="pre">Ignore</span> <span class="pre">the</span> <span class="pre">following</span> <span class="pre">groups</span> <span class="pre">when</span> <span class="pre">checking</span> <span class="pre">group</span> <span class="pre">membership</span></code> won’t be taken in account to determine if users are in same groups and may share with each others.</p></li> </ul> <div class="admonition note"> <p class="admonition-title">Note</p> <p>This setting does not apply to the Federated Cloud sharing feature. If <a class="reference internal" href="federated_cloud_sharing_configuration.html"><span class="doc">Federated Cloud Sharing</span></a> is enabled, users can still share items with any users on any instances (including the one they are on) via a remote share.</p> </div> </li> </ul> </li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">users</span> <span class="pre">to</span> <span class="pre">share</span> <span class="pre">via</span> <span class="pre">link</span> <span class="pre">and</span> <span class="pre">email</span></code> to enable creating public shares for people who are not Nextcloud users via hyperlink.</p> <ul class="simple"> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">public</span> <span class="pre">uploads</span></code> to allow anyone to upload files to public shares.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Always</span> <span class="pre">ask</span> <span class="pre">for</span> <span class="pre">a</span> <span class="pre">password</span></code> to proactively ask a user to set a password for a share link.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Enforce</span> <span class="pre">password</span> <span class="pre">protection</span></code> to force users to set a password on all public share links. This does not apply to local user and group shares.</p></li> <li><p>Add groups to <code class="docutils literal notranslate"><span class="pre">Exclude</span> <span class="pre">groups</span> <span class="pre">from</span> <span class="pre">creating</span> <span class="pre">link</span> <span class="pre">shares</span></code> to no apply the settings for that groups.</p></li> </ul> </li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Exclude</span> <span class="pre">groups</span> <span class="pre">from</span> <span class="pre">sharing</span></code> to prevent members of specific groups from creating any file shares in those groups. When you check this, you’ll get a dropdown list of all your groups to choose from. Type any group name to search for. Members of excluded groups can still receive shares, but not create any.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Set</span> <span class="pre">default</span> <span class="pre">expiration</span> <span class="pre">date</span> <span class="pre">for</span> <span class="pre">shares</span></code> to set a default expiration date on local user and group shares.</p> <ul> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Enforce</span> <span class="pre">expiration</span> <span class="pre">date</span></code> to always enforce the configured expiration date on local user and group shares.</p> <div class="admonition note"> <p class="admonition-title">Note</p> <p>Users will not be able to set the expiration date further in the future than the enforced expiration date, although they will be able to set a more recent date. Also note that users will be able to update the expiration date again at a later point. The expiration date is based on the current date and not on the share creation date. The user will be able to extend the expiration date again whenever a previous expiration date is close to be reached.</p> </div> </li> </ul> </li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Set</span> <span class="pre">default</span> <span class="pre">expiration</span> <span class="pre">date</span> <span class="pre">for</span> <span class="pre">shares</span> <span class="pre">via</span> <span class="pre">link</span> <span class="pre">or</span> <span class="pre">email</span></code> to set a default expiration date on public shares.</p> <ul> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Enforce</span> <span class="pre">expiration</span> <span class="pre">date</span></code> to always enforce the configured expiration date on public shares.</p> <div class="admonition note"> <p class="admonition-title">Note</p> <p>Users will not be able to set the expiration date further in the future than the enforced expiration date, although they will be able to set a more recent date. Also note that users will be able to update the expiration date again at a later point. The expiration date is based on the current date and not on the share creation date. The user will be able to extend the expiration date again whenever a previous expiration date is close to be reached.</p> </div> </li> </ul> </li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">username</span> <span class="pre">autocompletion</span> <span class="pre">in</span> <span class="pre">share</span> <span class="pre">dialog</span> <span class="pre">and</span> <span class="pre">allow</span> <span class="pre">access</span> <span class="pre">to</span> <span class="pre">the</span> <span class="pre">system</span> <span class="pre">address</span> <span class="pre">book</span></code> to enable auto-completion of Nextcloud usernames and list the system address book as resource when syncing contacts with CardDAV.</p> <ul class="simple"> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">username</span> <span class="pre">autocompletion</span> <span class="pre">to</span> <span class="pre">users</span> <span class="pre">within</span> <span class="pre">the</span> <span class="pre">same</span> <span class="pre">groups</span> <span class="pre">and</span> <span class="pre">limit</span> <span class="pre">system</span> <span class="pre">address</span> <span class="pre">books</span> <span class="pre">to</span> <span class="pre">users</span> <span class="pre">in</span> <span class="pre">the</span> <span class="pre">same</span> <span class="pre">groups</span></code> to limit username autocompletion to users from within the same groups as the share owner.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">username</span> <span class="pre">autocompletion</span> <span class="pre">to</span> <span class="pre">users</span> <span class="pre">based</span> <span class="pre">on</span> <span class="pre">phone</span> <span class="pre">number</span> <span class="pre">integration</span></code> to limit username autocompletion to users when the share owner has synced their phone address book via the Nextcloud Talk mobile clients and it contained the phone number the user configured in their profile.</p></li> </ul> </li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">autocompletion</span> <span class="pre">when</span> <span class="pre">entering</span> <span class="pre">the</span> <span class="pre">full</span> <span class="pre">name</span> <span class="pre">or</span> <span class="pre">email</span> <span class="pre">address</span> <span class="pre">(ignoring</span> <span class="pre">missing</span> <span class="pre">phonebook</span> <span class="pre">match</span> <span class="pre">and</span> <span class="pre">being</span> <span class="pre">in</span> <span class="pre">the</span> <span class="pre">same</span> <span class="pre">group)</span></code> to show despite of the previous restrictions a user suggestion, when the complete display name or user id was typed.</p></li> <li><p>Check <code class="docutils literal notranslate"><span class="pre">Show</span> <span class="pre">disclaimer</span> <span class="pre">text</span> <span class="pre">on</span> <span class="pre">the</span> <span class="pre">public</span> <span class="pre">link</span> <span class="pre">upload</span> <span class="pre">page</span></code> to set and show a disclaimer text on public links with hidden file lists. If you enable this feature a text input will be shown to input the disclaimer text.</p></li> </ul> <p>With <code class="docutils literal notranslate"><span class="pre">Default</span> <span class="pre">share</span> <span class="pre">permissions</span></code> you are able to set the default permissions for user-shares (<code class="docutils literal notranslate"><span class="pre">Create</span></code>, <code class="docutils literal notranslate"><span class="pre">Change</span></code>, <code class="docutils literal notranslate"><span class="pre">Delete</span></code> and <code class="docutils literal notranslate"><span class="pre">Reshare</span></code>) without forcing them.</p> <div class="admonition note"> <p class="admonition-title">Note</p> <p>Nextcloud does not preserve the mtime (modification time) of directories, though it does update the mtimes on files. See <a class="reference external" href="https://github.com/owncloud/core/issues/7009">Wrong folder date when syncing</a> for discussion of this.</p> </div> <div class="admonition note"> <p class="admonition-title">Note</p> <p>There are more sharing options on config.php level available: <a class="reference external" href="https://docs.nextcloud.com/server/33/admin_manual/configuration_server/config_sample_php_parameters.html#sharing">Configuration Parameters</a></p> </div> <section id="advanced-settings"> <span id="transfer-userfiles-label"></span><h2>Advanced settings<a class="headerlink" href="#advanced-settings" title="Link to this heading"></a></h2> <p>Here are some edge case settings which are not editable from the web interface, because they are only useful to small subset of administrators.</p> <p>You can use the <code class="docutils literal notranslate"><span class="pre">occ</span></code> command to update those, for example:</p> <div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>occ<span class="w"> </span>config:app:set<span class="w"> </span>core<span class="w"> </span>shareapi_restrict_user_enumeration_full_match_email<span class="w"> </span>--value<span class="w"> </span>yes </pre></div> </div> <ul> <li><dl> <dt><code class="docutils literal notranslate"><span class="pre">core.shareapi_restrict_user_enumeration_full_match_ignore_second_display_name</span></code></dt><dd><ul> <li><p>When full match is activated, ignore the appended second display name.</p></li> <li><p>Default: <code class="docutils literal notranslate"><span class="pre">no</span></code></p></li> <li><p>Examples:</p> <table class="docutils align-default"> <thead> <tr class="row-odd"><th class="head"><p>Setting value</p></th> <th class="head"><p>Search query</p></th> <th class="head"><p>User name</p></th> <th class="head"><p>Will match</p></th> </tr> </thead> <tbody> <tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">yes</span></code></p></td> <td><p>User 1</p></td> <td><p>User 1 (Second display name)</p></td> <td><p>yes</p></td> </tr> <tr class="row-odd"><td><p><code class="docutils literal notranslate"><span class="pre">no</span></code></p></td> <td><p>User 1</p></td> <td><p>User 1 (Second display name)</p></td> <td><p>no</p></td> </tr> </tbody> </table> </li> </ul> </dd> </dl> </li> <li><dl class="simple"> <dt><code class="docutils literal notranslate"><span class="pre">core.shareapi_restrict_user_enumeration_full_match_userid</span></code></dt><dd><ul class="simple"> <li><p>When full match is activated, do not match user ID</p></li> <li><p>Default: <code class="docutils literal notranslate"><span class="pre">yes</span></code></p></li> </ul> </dd> </dl> </li> <li><dl class="simple"> <dt><code class="docutils literal notranslate"><span class="pre">core.shareapi_restrict_user_enumeration_full_match_email</span></code></dt><dd><ul class="simple"> <li><p>When full match is activated, do not match user email</p></li> <li><p>Default: <code class="docutils literal notranslate"><span class="pre">yes</span></code></p></li> </ul> </dd> </dl> </li> </ul> </section> <section id="distinguish-between-max-expiration-date-and-default-expiration-date"> <h2>Distinguish between max expiration date and default expiration date<a class="headerlink" href="#distinguish-between-max-expiration-date-and-default-expiration-date" title="Link to this heading"></a></h2> <p>The expiration date which can be set and enforced in the settings above are the hard limit and the default value at the same time. Sometimes admins want to have a moderate default expire date, for example 7 days but make sure that the user can’t extend it to more than 14 days.</p> <p>In order to do so, set a enforced expiration date in the settings as described above and set the default value to something below the maximal possible expiration date with the following OCC commands:</p> <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">occ</span> <span class="n">config</span><span class="p">:</span><span class="n">app</span><span class="p">:</span><span class="nb">set</span> <span class="o">--</span><span class="n">value</span> <span class="o"><</span><span class="n">DAYS</span><span class="o">></span> <span class="n">core</span> <span class="n">internal_defaultExpDays</span> <span class="n">occ</span> <span class="n">config</span><span class="p">:</span><span class="n">app</span><span class="p">:</span><span class="nb">set</span> <span class="o">--</span><span class="n">value</span> <span class="o"><</span><span class="n">DAYS</span><span class="o">></span> <span class="n">core</span> <span class="n">link_defaultExpDays</span> </pre></div> </div> </section> <section id="get-a-notification-before-a-share-expires"> <h2>Get a notification before a share expires<a class="headerlink" href="#get-a-notification-before-a-share-expires" title="Link to this heading"></a></h2> <p>Users can get a notification before a share expires. In order to do so a cronjob need to be configured which calls the following OCC command once a day:</p> <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">occ</span> <span class="n">sharing</span><span class="p">:</span><span class="n">expiration</span><span class="o">-</span><span class="n">notification</span> </pre></div> </div> <p>A notification will be send for all shares which expire within the next 24 hours.</p> </section> <section id="transferring-files-to-another-user"> <h2>Transferring files to another user<a class="headerlink" href="#transferring-files-to-another-user" title="Link to this heading"></a></h2> <p>You may transfer files from one user to another with <code class="docutils literal notranslate"><span class="pre">occ</span></code>. This is useful when you have to remove a user. Be sure to transfer the files before you delete the user! This transfers all files from user1 to user2, and the shares and metadata info associated with those files (shares, tags, comments, etc). Trashbin contents are not transferred:</p> <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">occ</span> <span class="n">files</span><span class="p">:</span><span class="n">transfer</span><span class="o">-</span><span class="n">ownership</span> <span class="n">user1</span> <span class="n">user2</span> </pre></div> </div> <p>(See <a class="reference internal" href="../occ_command.html"><span class="doc">Using the occ command</span></a> for a complete <code class="docutils literal notranslate"><span class="pre">occ</span></code> reference.)</p> <p>Users may also transfer files or folders selectively by themselves. See <a class="reference external" href="https://docs.nextcloud.com/server/33/user_manual/en/files/transfer_ownership.html">user documentation</a> for details.</p> </section> <section id="creating-persistent-file-shares"> <h2>Creating persistent file Shares<a class="headerlink" href="#creating-persistent-file-shares" title="Link to this heading"></a></h2> <p>When a user is deleted, their files are also deleted. As you can imagine, this is a problem if they created file shares that need to be preserved, because these disappear as well. In Nextcloud files are tied to their owners, so whatever happens to the file owner also happens to the files.</p> <p>One solution is to create persistent shares for your users. You can retain ownership of them, or you could create a special user for the purpose of establishing permanent file shares. Simply create a shared folder in the usual way, and share it with the users or groups who need to use it. Set the appropriate permissions on it, and then no matter which users come and go, the file shares will remain. Because all files added to the share, or edited in it, automatically become owned by the owner of the share regardless of who adds or edits them.</p> </section> <section id="using-file-drop-share-links"> <h2>Using File Drop Share links<a class="headerlink" href="#using-file-drop-share-links" title="Link to this heading"></a></h2> <p>Using a File Drop Share allows users to upload files to Nextcloud through an unauthenticated session. File Drop Share links will only work when <code class="docutils literal notranslate"><span class="pre">Allow</span> <span class="pre">public</span> <span class="pre">uploads</span></code> is checked in the Sharing section of the Administration Settings page.</p> <div class="admonition note"> <p class="admonition-title">Note</p> <p>File Drop Shares currently have a limitation in that any files uploaded through an unauthenticated session will not be chunked. Therefore the maximum file size that can be uploaded through File Drop Shares depends entirely on settings set within your environment.</p> </div> </section> </section> </div> </div> <footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer"> <a href="index.html" class="btn btn-neutral float-left" title="File sharing and management" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a> <a href="federated_cloud_sharing_configuration.html" class="btn btn-neutral float-right" title="Configuring Federation Sharing" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a> </div> <hr/> <div role="contentinfo"> <p>© Copyright 2016-2026 Nextcloud GmbH and Nextcloud contributors.</p> </div> </footer> </div> </div> </section> </div> <div class="rst-versions" data-toggle="rst-versions" role="note" aria-label="versions"> <span class="rst-current-version" data-toggle="rst-current-version"> ☁️ latest <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> <dl> <dt>☁️ Versions</dt> <dd style="width: 32%"> <a href="https://docs.nextcloud.com/server/latest/admin_manual" style="color: var(--dark-link-color);" > latest </a> </dd> <dd style="width: 32%"> <a href="https://docs.nextcloud.com/server/stable/admin_manual" > stable </a> </dd> <dd style="width: 32%"> <a href="https://docs.nextcloud.com/server/32/admin_manual" > 32 </a> </dd> <dd style="width: 32%"> <a href="https://docs.nextcloud.com/server/31/admin_manual" > 31 </a> </dd> </dl> </div> </div> <script> jQuery(function () { SphinxRtdTheme.Navigation.enable(true); }); </script> </body> </html>
Save File
Cancel