Paperless-ngx transforms scanned documents and PDFs into a searchable, tagged, self-hosted document archive — automatically extracting text via OCR and organizing your paperwork digitally.
What Paperless-ngx Does
Watches a folder for new documents (scanned or PDF), runs OCR to extract text, and lets you tag, search, and organize everything through a web interface — effectively a self-hosted digital filing cabinet.
Prerequisites
- Docker and Docker Compose installed
Step 1 — Create a Project Directory
mkdir paperless-ngx && cd paperless-ngx
Step 2 — Download the Docker Compose Files
curl -o docker-compose.yml https://raw.githubusercontent.com/paperless-ngx/paperless-ngx/main/docker/compose/docker-compose.sqlite.yml
curl -o .env https://raw.githubusercontent.com/paperless-ngx/paperless-ngx/main/docker/compose/.env
Step 3 — Configure Environment Variables
nano .env
PAPERLESS_SECRET_KEY=CHANGE_ME_RANDOM_STRING
USERMAP_UID=1000
USERMAP_GID=1000
Step 4 — Start Paperless-ngx
docker compose up -d
Step 5 — Create Your Superuser Account
docker compose exec webserver python3 manage.py createsuperuser
Step 6 — Access the Web Interface
http://YOUR_SERVER_IP:8000
Step 7 — Add Documents via the Consume Folder
Drop scanned documents/PDFs into the mounted consume directory — Paperless-ngx automatically detects, OCRs, and processes them into your searchable archive.
Step 8 — Set Up Tags and Document Types
Configure tags (bills, receipts, contracts) and document types to keep your growing archive organized — Paperless-ngx also supports rules for automatically applying tags based on document content patterns.
Uploading via Email (Optional)
Paperless-ngx supports monitoring an email inbox and automatically importing attachments as documents — configure under the mail settings if you want to forward scanned documents by email for automatic processing.
Mobile Scanning Integration
Several mobile scanning apps can integrate directly with Paperless-ngx's API, letting you scan a document with your phone and have it appear automatically in your archive.
Add HTTPS
See How to Install Nginx Proxy Manager with Docker — important given the potentially sensitive nature of documents (bills, contracts, personal records) stored in this archive.
Backing Up Paperless-ngx
docker compose exec webserver document_exporter ../export
Paperless-ngx includes a built-in export tool producing a complete backup of documents and metadata — incorporate this into your regular backup routine (see How to Set Up Automated VPS Backups).
Common Errors
OCR text extraction quality is poor — verify the source scan quality/resolution is adequate; OCR accuracy depends significantly on input image quality.
Continue Reading
- How to Set Up Automated VPS Backups
- How to Install Nginx Proxy Manager with Docker
- Backup Encryption: Protecting Your Backups from Unauthorized Access
Browse more articles in Popular Self-Hosted Applications.