PHPackages                             dodjango/paperless\_attach - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. dodjango/paperless\_attach

ActiveRoundcube-plugin[Mail &amp; Notifications](/categories/mail)

dodjango/paperless\_attach
==========================

Attach documents from a Paperless-ngx instance directly into the Roundcube compose flow (Elastic skin).

v1.2.1(1mo ago)30[3 PRs](https://github.com/dodjango/roundcube-paperless-attach/pulls)GPL-3.0-or-laterPHPPHP &gt;=7.4CI passing

Since Jun 2Pushed 1w agoCompare

[ Source](https://github.com/dodjango/roundcube-paperless-attach)[ Packagist](https://packagist.org/packages/dodjango/paperless_attach)[ Docs](https://github.com/dodjango/roundcube-paperless-attach)[ RSS](/packages/dodjango-paperless-attach/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (4)Dependencies (3)Versions (7)Used By (0)

Paperless Attach
================

[](#paperless-attach)

[![Release](https://camo.githubusercontent.com/639708374c03815e37c8fadf2b9cb8ae944c41babdfbcdf3653c78add6fc9531/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f646f646a616e676f2f726f756e64637562652d70617065726c6573732d6174746163683f736f72743d73656d766572)](https://github.com/dodjango/roundcube-paperless-attach/releases)[![Tests](https://github.com/dodjango/roundcube-paperless-attach/actions/workflows/tests.yml/badge.svg)](https://github.com/dodjango/roundcube-paperless-attach/actions/workflows/tests.yml)[![License: GPL v3](https://camo.githubusercontent.com/6b8d7ad7a3702389f74a27a2f5b0ab9e9b7774aee6b03ce273edce1096f90ac8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d47504c76332d626c75652e737667)](LICENSE)[![Roundcube 1.6.x](https://camo.githubusercontent.com/77dbfc40dcf2e1c5a26900230a2ab04bbc7d8fb86009fd8f0a033530cff46d83/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f526f756e64637562652d312e362e782d333762656666)](https://camo.githubusercontent.com/77dbfc40dcf2e1c5a26900230a2ab04bbc7d8fb86009fd8f0a033530cff46d83/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f526f756e64637562652d312e362e782d333762656666)[![Paperless-ngx](https://camo.githubusercontent.com/594f18c902b67425c24ea760636bc1e976300287a649c57bc521c91776c745fc/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f50617065726c6573732d2d6e67782d4150492d313735343166)](https://camo.githubusercontent.com/594f18c902b67425c24ea760636bc1e976300287a649c57bc521c91776c745fc/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f50617065726c6573732d2d6e67782d4150492d313735343166)

A Roundcube (Elastic skin) plugin to attach documents from a [Paperless-ngx](https://docs.paperless-ngx.com/) instance straight from the compose window — search, filter, pick, attached. No download/re-upload detour. It works **both ways**: you can also **save an attachment from a received mail straight into Paperless** without leaving Roundcube. The per-user API token is stored **encrypted** and all Paperless traffic stays **server-side**.

[![Paperless picker dialog with search, filters and results](docs/screenshots/picker-dialog.png)](docs/screenshots/picker-dialog.png)

[![End-to-end demo: searching Paperless from compose, picking a document, and attaching it](docs/screenshots/demo.gif)](docs/screenshots/demo.gif)

Features
--------

[](#features)

- 🔍 Search + filter your documents — full-text, tags, correspondent, document type, date range — and multi-select across pages.
- 🖇️ Attaches the searchable **archive PDF**, fetched server-side.
- 📥 **Save received attachments to Paperless** — a per-attachment button (and one in the attachment preview toolbar after *Open*) uploads the file server-side; the async import is polled and reported (saved ✓ / already exists / failed).
- 🔐 Token stored encrypted; token + Paperless URL never reach the browser (single server-side proxy).
- 🧰 Oversize rejected before download, born-digital docs skipped, per-item batch results, no duplicate attaches.
- 🐳 Survives `:latest` (bind-mount + `ROUNDCUBEMAIL_PLUGINS`, no image build).

Compose buttonSettings — token + connection test[![Compose button](docs/screenshots/compose-button.png)](docs/screenshots/compose-button.png)[![Settings section](docs/screenshots/settings-connection.png)](docs/screenshots/settings-connection.png)Document titles, correspondents and the sender address are blurred in the screenshots.

Requirements
------------

[](#requirements)

Roundcube **1.6.x** · **Elastic** skin only · PHP **7.4+** · a reachable Paperless-ngx instance.

Install
-------

[](#install)

**Composer** (from your Roundcube root):

```
composer require dodjango/paperless_attach
```

**Docker bind-mount** (recommended for `roundcube/roundcubemail:latest` — survives image updates):

```
services:
  roundcubemail:
    volumes:
      - ./plugins/paperless_attach:/var/www/html/plugins/paperless_attach:ro
    environment:
      - ROUNDCUBEMAIL_PLUGINS=archive,zipdownload,...,paperless_attach   # append, keep the rest
      - ROUNDCUBEMAIL_DES_KEY=                    # encrypts the token
```

Set PHP `upload_max_filesize` / `post_max_size` / `memory_limit` **≥** your Roundcube upload limit, otherwise the effective attachment cap drops to the lower value.

> ⚠️ **Never change `des_key` after tokens are stored** — it makes all stored tokens (and sessions) undecryptable; every user would have to re-enter their token. Pin it once.

Configure
---------

[](#configure)

- **Token** (per user): *Settings → Paperless* → paste your Paperless API token → *Save* → *Test connection*.
- **Paperless URL** (server-side): copy `config.inc.php.dist` → `config.inc.php` and set `$config['paperless_url']`. It is server-fixed (SSRF guard — no per-user URL field); the default `http://paperless-webserver:8000` is an internal Docker hostname, so most installs must change it.
- **Max upload size** (optional, server-side): `$config['paperless_max_upload_size']` caps a received attachment uploaded to Paperless (default `100M`; `0` disables the guard).

Security
--------

[](#security)

Token encrypted via `rcube::encrypt()` — never stored in DB plaintext, echoed to the field, or placed in `rcmail.env`/AJAX. All Paperless calls originate from one server-side proxy (`lib/PaperlessClient.php`) with redirects disabled, enforced timeouts, and integer-validated document ids. Designed for **internal-network** use.

Status
------

[](#status)

In daily use on the author's self-hosted stack. Best-effort community plugin (no warranty), so far verified on a single deployment; testing on other Roundcube 1.6.x setups, issues and PRs are very welcome.

Contributing &amp; releases
---------------------------

[](#contributing--releases)

[Conventional Commits](https://www.conventionalcommits.org/) + [Semantic Versioning](https://semver.org/), released automatically via [release-please](https://github.com/googleapis/release-please). See [`CONTRIBUTING.md`](CONTRIBUTING.md).

**Tests:** a PHPUnit suite covers the server-side Paperless client (`lib/PaperlessClient.php`) — run `composer install && composer test`. CI runs it on PHP 7.4 / 8.0 / 8.1.

Out of scope (v2)
-----------------

[](#out-of-scope-v2)

Archive-vs-original choice per document · inline PDF preview · saved searches · skins other than Elastic.

Author &amp; license
--------------------

[](#author--license)

Created and maintained by **[@dodjango](https://github.com/dodjango)**. Built with the help of AI tooling (Claude); all code is human-reviewed and live-tested.

Licensed under **GPL-3.0-or-later** — see [`LICENSE`](LICENSE).

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance94

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

 Bus Factor1

Top contributor holds 70% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

4

Last Release

47d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/8327172?v=4)[Torsten Mattetat](/maintainers/dodjango)[@dodjango](https://github.com/dodjango)

---

Top Contributors

[![dodjango](https://avatars.githubusercontent.com/u/8327172?v=4)](https://github.com/dodjango "dodjango (14 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (3 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (3 commits)")

---

Tags

attachmentsemailpaperlesspaperless-ngxphproundcuberoundcube-pluginself-hostedselfhostedwebmailpluginroundcubeattachmentself hostedpaperlesspaperless-ngx

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/dodjango-paperless-attach/health.svg)

```
[![Health](https://phpackages.com/badges/dodjango-paperless-attach/health.svg)](https://phpackages.com/packages/dodjango-paperless-attach)
```

###  Alternatives

[toteph42/identity_switch

This plugin allows users to switch between different identities (and check for new mails) in a single Roundcube session.

221.5k](/packages/toteph42-identity-switch)[kartik-v/yii2-widget-growl

A widget to generate growl based notifications using bootstrap-growl plugin (sub repo split from yii2-widgets)

424.4M14](/packages/kartik-v-yii2-widget-growl)[kartik-v/yii2-widget-alert

A widget to generate alert based notifications using bootstrap-alert plugin (sub repo split from yii2-widgets)

304.2M24](/packages/kartik-v-yii2-widget-alert)[railsware/mailtrap-php

The Mailtrap SDK provides methods for all API functions.

60929.1k](/packages/railsware-mailtrap-php)[vaibhavpandeyvpz/phemail

A pure PHP MIME parser for parsing raw email files (.eml) with full support for multipart messages, nested structures, and RFC 2046 compliance.

36130.4k2](/packages/vaibhavpandeyvpz-phemail)[dsoares/rcguard

Roundcube plugin that enforces reCAPTCHA for users that have too many failed logins

254.0k](/packages/dsoares-rcguard)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
