Skip to content

Share private files with anyone, and revoke access when you need to.

Recipients can be accounts on your site or anyone with an email address. People without an account sign in with a code or a single-use link sent to them.

For Drupal 10.5+ and 11 ยท PHP 8.2+

A staff member shares three files with an address and a domain. The invitee opens the emailed link, and someone at the domain signs in with a code. The staff member then reads the activity, removes a recipient along with the person they invited, and revokes the share. The next request is refused.

A share is a set of private files and media items plus a set of recipients: accounts, addresses, or *@domain patterns. Files are served only through File Share's own routes. On every request it checks the share, the recipient and the issuer's own access to the file, so revoking a share takes effect on the next request.

Requirements

  • Drupal core ^10.5 || ^11, PHP 8.2 or later.
  • A private file system ($settings['file_private_path']). Only private files can be shared.
  • Optional: Media, to share media items. A share follows a media item when its file is replaced.
  • Optional, for the File Share Tools submodule: Tool API 1.0.0-beta11 or later.

To install File Share and share your first files, see Install.

Features

Feature See
Share files and media items, uploaded or already on the site, with accounts, addresses and domains Sharing files
Sign-in by emailed code or single-use link, safe from mail scanners What recipients see
Recipients invite others; removing someone removes everyone they invited Revoking access
Revoke by share, by recipient across the site, or by issuer; blocking an account does both Revoking access
A log of every sign-in, download and refusal Sharing files
Drush commands and Tool API tools for agents such as Site Agent Drush, Tool API

Submodules

Module Does Status
File Share Tools Tool API plugins to create, change, list and revoke shares and read their activity. See Tool API and Site Agent. Experimental