PhotoPrism — AI-Powered Photo Management for the Self-Hosted Era
PhotoPrism organizes your photo library using AI-powered tagging, face recognition, and location clustering. A polished Google Photos alternative that keeps your photos on your own server.
Safe staging for this asset
This asset is staged first. The copied prompt tells the agent to inspect the staged files and ask before activating scripts, MCP config, or global config.
npx -y tokrepo@latest install 306cea9c-381e-11f1-9bc6-00163e2b0d79 --target codexStages files first; activation requires review of the staged README and plan.
What it is
PhotoPrism is a self-hosted photo management application that uses AI for automatic tagging, face recognition, and location clustering. It provides a polished web interface similar to Google Photos but runs entirely on your own hardware, giving you full control over your data.
The target audience includes privacy-conscious users who want cloud photo features without third-party data access, home lab enthusiasts, and photographers managing large libraries who need automatic organization.
How it saves time or tokens
PhotoPrism's AI classifiers automatically tag photos by content (landscapes, animals, food), recognize faces across your library, and cluster images by GPS coordinates on a world map. This eliminates hours of manual sorting. The search works across all metadata -- EXIF data, AI-generated tags, and user labels -- so finding a specific photo takes seconds.
For self-hosted setups, PhotoPrism indexes your existing folder structure without moving files. You keep your directory layout while gaining a searchable, browsable web interface.
How to use
- Deploy PhotoPrism with Docker Compose:
# docker-compose.yml
version: '3.5'
services:
photoprism:
image: photoprism/photoprism:latest
ports:
- '2342:2342'
environment:
PHOTOPRISM_ADMIN_PASSWORD: 'changeme'
PHOTOPRISM_SITE_URL: 'http://localhost:2342/'
PHOTOPRISM_ORIGINALS_LIMIT: 5000
volumes:
- './photos:/photoprism/originals'
- './storage:/photoprism/storage'
- Start the container:
docker compose up -d
- Open
http://localhost:2342, log in with admin credentials, and start indexing your photo library.
Example
Index photos and search by AI-detected content:
# Trigger indexing via the CLI
docker compose exec photoprism photoprism index
# Search via the API
curl 'http://localhost:2342/api/v1/photos?q=cat&count=10' \
-H 'X-Session-ID: your-session-token'
Related on TokRepo
- Self-hosted tools -- Privacy-first applications you run on your own infrastructure
- AI tools for content -- AI-powered content organization and management
Common pitfalls
- Initial indexing of large libraries (50K+ photos) takes hours and is CPU-intensive. Run the first index overnight or allocate dedicated CPU cores.
- Face recognition accuracy improves with more photos of the same person. Small libraries may produce false matches that need manual correction.
- PhotoPrism stores processed thumbnails and metadata in the storage volume. Ensure this volume has enough disk space (roughly 1-2 GB per 10K photos).
- RAW file support depends on pre-installed codecs. Some camera-specific RAW formats require additional sidecar conversion.
- HTTPS requires a reverse proxy (Nginx, Caddy) in front of PhotoPrism. The built-in server does not handle TLS directly.
Frequently Asked Questions
No. PhotoPrism's AI classifiers run on CPU by default using TensorFlow Lite. A GPU accelerates indexing speed but is not required. Most users run PhotoPrism on modest hardware like a Raspberry Pi 4 or a NAS with 4GB RAM.
Yes. Use Google Takeout to export your library as a ZIP archive, extract the photos into PhotoPrism's originals directory, and run the indexer. PhotoPrism reads EXIF metadata and Google's JSON sidecar files for dates and locations.
Yes. PhotoPrism indexes video files alongside photos, generates thumbnails, and allows playback in the web UI. It supports common formats including MP4, MOV, and AVI. Transcoding uses FFmpeg under the hood.
Back up both the originals directory (your photos) and the storage directory (database, thumbnails, sidecar files). If using the built-in SQLite database, copy the database file while PhotoPrism is stopped. For MariaDB, use mysqldump.
PhotoPrism supports multiple user accounts with different roles (admin, viewer). Each user sees the same library but can have private albums and favorites. Fine-grained per-folder permissions are not yet available.
Citations (3)
- PhotoPrism GitHub— PhotoPrism uses AI-powered tagging and face recognition
- PhotoPrism Official— Self-hosted Google Photos alternative with privacy focus
- PhotoPrism Docs— TensorFlow Lite for on-device AI classification
Related on TokRepo
Discussion
Related Assets
Immich — High-Performance Self-Hosted Photo & Video Management
Immich is an open-source Google Photos alternative with auto-backup, AI-powered search, face recognition, and mobile apps — self-hosted for complete privacy.
LibrePhotos — Self-Hosted AI-Powered Photo Management
A self-hosted open-source photo management service with automatic face recognition, object detection, and geolocation tagging powered by machine learning.
Lychee — Self-Hosted Photo Management System
A beautiful, easy-to-use photo management system you can run on your server to upload, organize, and share photo albums.
Piwigo — Self-Hosted Photo Gallery and Management Platform
Open-source photo gallery application built for organizations and photographers. Manages large photo collections with albums, tags, batch uploads, user permissions, and a plugin ecosystem for extending functionality.