DEV Community

Cover image for Self-Hosted File Sharing with Expiring Links: 6 Options Compared
Lexis
Lexis

Posted on

Self-Hosted File Sharing with Expiring Links: 6 Options Compared

Emailing a 2 GB ZIP to a client fails. Dropping it into a consumer cloud folder works, but the link lives forever and nobody remembers to revoke it. If you run your own server, you can do better: links that expire, need a password, stop working after a few downloads, and leave a log behind.

This guide covers six self-hosted options, from single-purpose transfer apps to full file platforms, with config tips taken from each project's own documentation.

What does a good expiring share link need?

Before comparing tools, it helps to list what "secure" means for a client handoff:

  • Expiry: the link dies on a date, ideally with an admin-enforced maximum so nobody creates a link that lasts forever.
  • Password: a second factor sent through a different channel than the link.
  • Download or visitor limits: a link that works once is much less dangerous if it leaks.
  • Audit trail: a record of who created a share and, where possible, who opened it.
  • Admin policy: defaults that users cannot quietly switch off.

No tool below does all five equally well. The trade-off is usually between a lightweight transfer app (fast to deploy, few controls) and a full platform (more controls, more to maintain).

Nextcloud: share links inside a full file platform

If you already run Nextcloud (AGPL-3.0), you have expiring links today. According to the user manual, a public link can be password protected, given an expiration date that disables the share automatically, set to read-only or to allow uploads, and set to "hide download", which hides the download buttons and the default right-click options.

The more useful part for sysadmins is enforcement. Under Administration settings, Sharing, the admin manual documents "Enforce password protection" and "Set default expiration date", with a nested "Enforce expiration date" that lets users pick an earlier date but never a later one. The number of days has no field in the web UI; set it with OCC:

occ config:app:set --value 7 core link_defaultExpDays
Enter fullscreen mode Exit fullscreen mode

For an audit trail, don't rely on the Activity stream. The Activity docs say plainly that users can disable tracking, so it "is not a reliable audit trail", and point to the admin_audit app instead. Its log goes to audit.log by default (configurable with logfile_audit), and because audit messages are written at INFO level, the logging docs note you need to lower the log level or add a log.condition for them to appear.

Trade-off: Nextcloud is a lot of software to run just for share links. If file sync, calendars and apps are not on your roadmap, it's heavy.

Seafile: strict link policies from one config file

Seafile splits its licensing by component: the server core is AGPLv3 and the Seahub web UI is Apache 2.0. Its share link controls live in seahub_settings.py, which makes policy easy to review in version control. From the settings reference:

SHARE_LINK_FORCE_USE_PASSWORD = True
SHARE_LINK_PASSWORD_MIN_LENGTH = 10
SHARE_LINK_EXPIRE_DAYS_DEFAULT = 7
SHARE_LINK_EXPIRE_DAYS_MIN = 1
SHARE_LINK_EXPIRE_DAYS_MAX = 30
Enter fullscreen mode Exit fullscreen mode

Once a default expiry is set, users can no longer create links that never expire. SHARE_LINK_LOGIN_REQUIRED forces viewers to log in, which suits internal shares. On the Pro edition, ENABLE_SHARE_LINK_AUDIT asks anonymous visitors for an email address before they download or upload, which gives you a lightweight record of who opened a link.

Trade-off: that audit option is Pro-only, and Seafile is still a sync platform with its own storage model to learn.

PsiTransfer: the smallest thing that works

PsiTransfer (BSD-2-Clause) is a single-purpose upload-and-share app with no accounts. Uploads go into a "bucket" with an expiry time, an optional password on the download list, and an optional one-time download. Uploads and downloads are resumable, which matters for large video or design files on flaky connections.

The README's Docker command is one line:

docker run -p 3000:3000 -e PSITRANSFER_ADMIN_PASS=secret \
  -v $PWD/data:/data psitrax/psitransfer
Enter fullscreen mode Exit fullscreen mode

Two documented tips: the data volume must be owned by UID 1000, and if the instance faces the internet, set PSITRANSFER_UPLOAD_PASS so strangers can't use your server as free storage. Expiry choices come from the retentions map in config.js, which ships with options from "one time download" up to eight weeks and a default of one week.

Trade-off: no user accounts means no per-user audit trail. The /admin page (enabled by PSITRANSFER_ADMIN_PASS) is about it.

Send: encrypted, self-destructing transfers

Mozilla discontinued Firefox Send, but the community fork by timvisee (MPL-2.0, primary repo on GitLab) keeps it alive. Its key property is that, per the encryption docs, files are encrypted in the browser before upload and the key is appended to the share URL as a #fragment, so the server stores only ciphertext. Senders can add a password too.

Limits are environment variables, documented in docs/docker.md:

-e MAX_EXPIRE_SECONDS=604800   # max link lifetime (default 7 days)
-e DEFAULT_DOWNLOADS=1         # download limit preselected in the UI
-e MAX_DOWNLOADS=100
-e MAX_FILE_SIZE=2147483648    # 2 GB default
-e BASE_URL=https://send.example.com
Enter fullscreen mode Exit fullscreen mode

Redis is required in production.

Trade-off: because the server can't read files, it also can't preview, scan or index them. And like PsiTransfer, it's a transfer tool, not a place to keep a project's files.

Pingvin Share: check which repo you deploy

Pingvin Share was a popular answer to this question, but the original repository is archived and read-only; its README says the author stopped maintaining it in 2025 and recommends the fork Pingvin Share X. Any old tutorial pointing at the original image is pointing at unmaintained code.

Pingvin Share X (BSD-2-Clause) keeps the feature set: shares with expiration dates, passwords and visitor limits, email recipients, reverse shares (let a client upload to you), OIDC and LDAP login, ClamAV scanning, and local or S3 storage. Install is a downloaded docker-compose.yml and docker compose up -d.

Trade-off: it's a young fork maintained by a different team than the original, so check its recent releases and open issues before making it a long-term dependency.

Drumee: secure shares inside a client workspace

The tools above treat sharing as a one-off event. Drumee (AGPL-3.0) approaches it from the other side: files, chat, tasks and meetings live in one workspace, and a client can get an external workspace or guest access instead of a stream of separate links. Secure share links come with options such as password and expiry, and folders use a permissions matrix (view, chat, edit, admin), so "client can view but not edit" is a setting rather than a convention. Version history and chat threads attached to folders and files keep feedback next to the deliverable it refers to.

Client files, grouped and locked in one place

It can be used on Drumee-hosted plans or self-hosted as a Sovereign Node on your own infrastructure. Audit logs are part of the Business plan. If you're weighing it against a file platform, the team has a longer write-up on secure self-hosted file sharing.

Trade-offs: Drumee is younger, with a smaller ecosystem and fewer integrations than Nextcloud. Task planning is lighter than a dedicated PM tool, and it doesn't claim real-time co-editing of office documents. And if all you need is "send this file once", a workspace is more than the job requires.

How do the options compare?

Comparison: Nextcloud, Seafile, PsiTransfer, Send (fork), Pingvin Share X, Drumee

Which one should you pick?

Start from where the files already live and how long the client relationship lasts.

Picking a self-hosted share tool

  • Pick Nextcloud if you already run it or want a full sync platform anyway. Turn on enforced passwords and expiry, set link_defaultExpDays, and enable admin_audit.
  • Pick Seafile if you want link policy written down in one reviewable config file, and especially if the Pro edition's email gate fits your audit needs.
  • Pick PsiTransfer for the fastest possible "upload, get link, it expires" setup with no accounts. Set an upload password before exposing it.
  • Pick Send when the server should never be able to read what passes through it, and one-download links are the norm.
  • Pick Pingvin Share X if you liked Pingvin Share and want reverse shares and virus scanning, but deploy the fork, not the archived original.
  • Pick Drumee if you're an agency or team with ongoing client work, where the share link is one part of a longer exchange of files, comments and meetings.

Whatever you choose, the setup checklist is the same: enforce a maximum expiry, require passwords and send them through another channel, keep links to a single download where you can, and make sure the logs you think you have are actually being written.

For readers who want to try it: Drumee's Team plan is $1 for the first month, then $29/month, for up to 10 members with 100 GB, guest access and secure, expiring share links. The offer is open to the first 100 startups until 30 November 2026 with code TEAM1_BLOG: claim the $1 month.

Disclosure: this post is written by the Drumee team, and Drumee is one of the tools covered. We've tried to keep it fair. Corrections welcome in the comments.

Top comments (0)