From ArchWiki
Jump to navigation Jump to search

Papermerge is an open source document management system for digital archives.


Install the papermergeAUR package. Installation and updates of the package automatically run the database migrations.


Enable and start the two papermerge systemd units:

# systemctl enable --now papermerge-gunicorn papermerge-worker

Your papermerge instance should now be available at port 9001.


For details on papermerge configuration, visit its official documentation. The main configuration file is located at /etc/

Note: The papermergeAUR package creates a papermerge system user and provides a papermerge-manage command which should always be run as the papermerge user. See below for an example. The papermerge-manage command should be used wherever the official documentation refers to

Do not forget to restart papermerge-gunicorn.service and papermerge-worker.service after changing configurations.

Create admin user

After initial installation, you should create an admin user for your papermerge instance:

$ sudo -u papermerge papermerge-manage createsuperuser


Install Nginx and use the following configuration as a starting point for the papermerge virtual host:

server {
    server_name papermerge.domain.tld;
    listen 80;
    listen [::]:80;

    location /static/ {
        alias /var/lib/papermerge/static/;

    location /media/ {
        alias /var/lib/papermerge/media/;

    location / {


It is recommended to use Redis as a message broker instead of the default filesystem-based approach.

Install redis and python-redis and start/enable redis.service. In /usr/lib/python3.9/site-packages/config/settings/ replace

CELERY_BROKER_URL = "filesystem://"
    'data_folder_in': PAPERMERGE_TASK_QUEUE_DIR,
    'data_folder_out': PAPERMERGE_TASK_QUEUE_DIR,


CELERY_BROKER_URL = "redis://"
CELERY_RESULT_BACKEND = "redis://localhost/0"

and restart papermerge-gunicorn.service and papermerge-worker.service