
Go paperless with Paperless-ngx on your home server. Docker Compose installation, scanner integration, OCR configuration, auto-tagging rules, and mobile app setup.
In the era of paperless offices, there's a powerful open-source tool that empowers you to bring the same efficiency to your home life. Paperless-ngx is a complete document management system designed to be self-hosted, enabling you to digitize, organize, and retrieve your important paperwork with ease. This guide will walk you through setting it up on your own low-power home server using Docker, turning your homelab into a personal digital filing cabinet.

Paperless-ngx is a fork and evolution of the original Paperless project, built as a modern web application for archiving, indexing, and retrieving your digital documents. It's not just a digital shoebox; it's an intelligent system. When you upload or scan a document, it performs Optical Character Recognition (OCR) to extract text, making the contents fully searchable. You can then tag documents, assign them to correspondents (like "Utility Company"), categorize them into document types (like "Invoice"), and store them in logical folders. The core value is the ability to instantly find any document—a warranty, a tax form, or a medical bill—by searching for words you remember were on it.
Self-hosting Paperless-ngx offers significant advantages over cloud-based alternatives like Google Drive or proprietary document scanners:

Before diving into the installation, ensure your environment meets these basic requirements.
/opt/paperless or /home/youruser/paperless-data is typical.To install Docker and Docker Compose on a fresh Debian/Ubuntu system, you can run the following:
# Update the package index
sudo apt update
# Install Docker and necessary tools
sudo apt install docker.io docker-compose-plugin
# Ensure the Docker daemon starts automatically
sudo systemctl enable docker --now
# Add your user to the docker group to run commands without sudo (log out/in after)
sudo usermod -aG docker $USER
For a Raspberry Pi running Raspberry Pi OS, the process is similar, but ensure you're using the 64-bit version (aarch64) for best compatibility.

The recommended and simplest way to run Paperless-ngx is via a docker-compose.yml file. This defines all necessary services (the web app, database, OCR engine, and message broker) and their relationships.
Create a new directory for your Paperless instance, navigate into it, and create the docker-compose.yml file.
mkdir ~/paperless-ngx
cd ~/paperless-ngx
Now, create the docker-compose.yml file with the following content. This is a standard, production-ready configuration that includes all core components.
version: "3.4"
services:
broker:
image: rabbitmq:latest
restart: unless-stopped
volumes:
- broker-data:/var/lib/rabbitmq
db:
image: postgres:15
restart: unless-stopped
volumes:
- db-data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=paperless
- POSTGRES_USER=paperless
- POSTGRES_PASSWORD=paperless
webserver:
image: ghcr.io/paperless-ngx/paperless-ngx:latest
restart: unless-stopped
depends_on:
- db
- broker
ports:
- "8000:8000"
volumes:
- data:/usr/src/paperless/data
- media:/usr/src/paperless/media
- export:/usr/src/paperless/export
- ./config:/usr/src/paperless/config
environment:
- PAPERLESS_REDIS=redis://broker:6379
- PAPERLESS_DBHOST=db
- PAPERLESS_DBNAME=paperless
- PAPERLESS_DBPASS=paperless
- PAPERLESS_DBUSER=paperless
- PAPERLESS_SECRET_KEY=change-this-to-a-long-random-string
- PAPERLESS_URL=http://localhost:8000
- PAPERLESS_TIME_ZONE=America/New_York
- PAPERLESS_OCR_LANGUAGE=eng
- PAPERLESS_CONSUMPTION_DIR=/usr/src/paperless/consume
volumes:
broker-data:
db-data:
data:
media:
export:
Important: You must change the PAPERLESS_SECRET_KEY value to a long, random string. This key secures your session data. You can generate one with a simple Python command: python3 -c "import secrets; print(secrets.token_urlsafe(64))".
With the file saved, you can start Paperless-ngx with a single command:
docker compose up -d
The -d flag runs the containers in detached mode (in the background). Docker will pull the required images and start all services. The initial startup might take a minute, especially on slower hardware. Once complete, Paperless-ngx will be accessible at http://YOUR_SERVER_IP:8000.
Upon first accessing the web interface (http://YOUR_SERVER_IP:8000), you'll be greeted by a setup wizard. The first step is to create a superuser account. This account has full administrative privileges.
After creating the superuser, log in. You should now see the main dashboard. Before you start consuming documents, there are a few critical settings to configure under Settings > Administration.
This is the directory where Paperless-ngx automatically imports documents from. In our docker-compose.yml, we defined it as /usr/src/paperless/consume inside the container. We need to mount a host directory to this path.
Stop the services (docker compose down) and add a new volume mount to the webserver service in your docker-compose.yml:
webserver:
# ... other configuration remains the same ...
volumes:
- data:/usr/src/paperless/data
- media:/usr/src/paperless/media
- export:/usr/src/paperless/export
- ./config:/usr/src/paperless/config
- ./consume:/usr/src/paperless/consume # Add this line
Create the consume directory in your Paperless folder (mkdir consume) and restart the stack (docker compose up -d). Now, any file (PDF, JPEG, PNG, TIFF) placed in the ./consume directory on your host will be automatically imported, OCR-processed, and added to Paperless.
Paperless can also import documents via email. This is incredibly useful for digitizing bills or statements you receive electronically. Under Settings > Mail, configure an email account (e.g., a dedicated Gmail address) using IMAP. Paperless will periodically check this inbox, and any email with an attachment will have that attachment imported as a document. The email subject becomes the document title, and the body can be used for auto-tagging.
Under Settings > General, verify the OCR language is set correctly (eng for English). You can also enable "Skip documents that already have text" to speed up processing of digital PDFs that are already searchable.
Paperless-ngx's power lies in its features for organization and automation. Here’s how to leverage them in your daily workflow.
These are the primary organizational pillars.
tax-2025, to-shred, medical, warranty-active. Use them for flexible, cross-cutting categorization.Electric Company, IRS, Doctor's Office.Invoice, Bank Statement, Contract, Receipt.Create these entities before mass importing documents. When you upload a document, you can manually assign these. The real magic, however, comes from Auto-Matching Rules.
Under Settings > Automation, you can create rules that automatically assign tags, correspondents, and types based on document content.
For example, create a rule that:
"ACME Utility Company".ACME Utility Company, assign document type Invoice, add tag urgent-payment.This means any scanned bill from ACME Utility is fully categorized upon import without any manual intervention.
This is the core day-to-day use case.
./consume directory on your Paperless server via SMB/CIFS (Windows Share).Once in the consumption directory, Paperless processes the document: it converts it to a standard format (PDF/A for archiving), runs OCR (using Apache Tika), applies auto-matching rules, and stores it. The original and archived versions are stored in the media volume, and the extracted text is indexed for search.
After processing, go to the Documents view. Use the search bar to find documents by any word within their content. Searching for "warranty period 24 months" will find that specific product manual. Click any document to view the archived PDF with the OCR text layer overlay.
Paperless-ngx is exceptionally well-suited for low-power homelab servers. Its workload is asynchronous and bursty—it idles most of the time and only consumes CPU/RAM during document import and OCR processing.
Here’s a breakdown of typical resource usage on popular low-power platforms:
| Hardware Platform | Idle State (no activity) | During OCR Processing (single document) | Notes |
|---|---|---|---|
| Intel N100 Mini PC (e.g., Beelink S12, 16GB RAM) | ~150 MB RAM, <5% CPU (1-2 cores idle) | ~500 MB RAM, 60-80% CPU (all 4 cores engaged) | The N100's efficient 4-core CPU handles OCR very quickly. Processing a 10-page PDF typically completes in 10-15 seconds. |
| Raspberry Pi 5 (8GB RAM) | ~180 MB RAM, <5% CPU | ~600 MB RAM, 85-100% CPU | OCR is the heaviest load. A 10-page PDF may take 20-30 seconds to process. Performance is very acceptable for home use. |
| Raspberry Pi 4 (4GB RAM) | ~160 MB RAM, <5% CPU | ~450 MB RAM, 100% CPU (sustained) | Slower, but functional. OCR times can extend to 45-60 seconds for multi-page documents. Best for lighter, occasional use. |
Key Takeaways for Low-Power Users:
consume directory via a mounted SMB share. This creates a true "scan-to-cloud" pipeline.to-shred. Once you've confirmed a document is correctly archived and categorized in Paperless, you can add this tag. This gives you a clear list of papers that are ready for physical destruction.paperless database password in the docker-compose.yml to a strong one.PAPERLESS_OCR_LANGUAGE to eng+fra+deu (English, French, German) in your docker-compose.yml environment variables to improve accuracy.Problem: Documents are not automatically importing from the consume directory.
Solution: Check that the volume mount is correct in your docker-compose.yml. Inside the Paperless container, run a test by executing docker compose exec webserver ls -la /usr/src/paperless/consume. Ensure the directory exists and has the correct permissions (read/write for the container). The consumer service runs periodically; a new document might take up to a minute to be picked up.
Problem: OCR is failing or producing gibberish text.
Solution: First, verify the document is not corrupted. Check the PAPERLESS_OCR_LANGUAGE setting in your environment variables. For scanned images, ensure they are reasonably clear and upright. Paperless uses Apache Tika, which is robust, but poor scan quality (low resolution, skewed pages, heavy shadows) will lead to bad OCR.
Problem: The web interface is slow or unresponsive on a Raspberry Pi.
Solution: This is often a memory issue. Check your total system memory usage with free -h. If you're running other services, consider limiting them or moving Paperless to a system with more RAM. You can also try reducing the Paperless worker count by adding PAPERLESS_WORKERS=1 to the webserver environment in your compose file.
Problem: "Login failed" after initial setup.
Solution: You are likely using the wrong credentials. The setup wizard creates a superuser. Ensure you are logging in with that username and password. If lost, you can create a new superuser via command line: docker compose exec webserver python manage.py createsuperuser.
Problem: Email consumption is not working.
Solution: Double-check your IMAP settings (server, port, SSL). Use an "App Password" if using Gmail. Check the Paperless logs for mail errors: docker compose logs webserver. The mail consumer runs on a schedule; it may not check instantly.
Paperless-ngx transforms the daunting task of document management into an automated, searchable, and secure digital archive. By self-hosting it on a low-power server like an Intel N100 mini PC or a Raspberry Pi 5, you gain complete control over your personal data without sacrificing performance or incurring ongoing costs. The initial setup via Docker Compose is straightforward, and the daily workflow—integrating a physical scanner, email, and a mobile app—becomes a seamless part of your life. Start by digitizing a small batch of recent documents, refine your auto-tagging rules, and gradually build your archive. You'll quickly find that the ability to locate any piece of paper in seconds is not just a convenience; it's a game-changer for home organization.

Use Cases
Self-host Paperless-ngx for document management. OCR setup, scanner integration, and automation tips for your home server.
Use Cases
Run your own Git server with Gitea. Docker Compose setup, SSH key authentication, mirroring GitHub repos, CI/CD with Gitea Actions, and resource usage on low-power hardware.
Use Cases
Self-host Bitwarden with Vaultwarden on your home server. Docker Compose setup, HTTPS with Nginx Proxy Manager, Tailscale remote access, and family sharing configuration.
Check out our build guides to get started with hardware.
View Build Guides