work/lightbox

Photo library browser

LIGHTBOX

A fast browser for a photo and video library of about 95,000 files, built to replace digiKam: by camera, year and month, with RAW previews, full metadata and zip downloads.

Live

The detail view and its metadata panel.

The library is about 95,000 photos and videos from 51 cameras, 1.6 TB in all, filed by camera, year and month. digiKam could open it, slowly. LIGHTBOX opens it in a browser tab in milliseconds.

The landing page shows cameras grouped by brand, each with a cover picture and a file count. Pick one and drill down by year and month, or jump into the folder view. The grid scrolls virtually, so even "View all" on the whole library keeps about 42 tiles in the page at a time. There's a filename search, an image or video filter and capture-date ordering.

Runs on
Web app on the home server, local network only
Built with
Node 22, zero npm dependencies, Redis, exiftool, libvips, Docker
Started
August 2026

Browse

  1. The landing page: cameras grouped by brand. The three cameras and all the pictures here are invented test fixtures.
    The landing page: cameras grouped by brand. The three cameras and all the pictures here are invented test fixtures.
  2. One camera, by year and month.
    One camera, by year and month.
  3. A month of photos, with the filename on hover.
    A month of photos, with the filename on hover.

Every file, opened properly

The detail view has a large preview, previous and next, and the full metadata: make, model, lens, ISO, shutter, aperture, focal length, dimensions and size. RAW files (CR2, ARW, DNG, RAF and friends) preview from the JPEG the camera embedded, with orientation repaired when the raw preview has none. Recent iPhone HEIC photos, HDR gain maps included, decode through a newer libheif. Add to pack collects files as you browse, and Download .zip streams them as an exact-size ZIP64 archive; any single original downloads directly.

Look closer

  1. The detail view and its metadata panel.
    The detail view and its metadata panel.
  2. A second photo, already in the pack.
    A second photo, already in the pack.
  3. The pack tray with two photos and Download .zip.
    The pack tray with two photos and Download .zip.

Measured on the real library

  • Full index of all 95,000 files: 38 minutes. A re-index with nothing changed: about 3 seconds.
  • Unfiltered views in 14 to 18 ms, filtered 13 to 23 ms.
  • Thumbnails succeeded for every format in the library: JPEG, RAF, CR2, ARW, DNG, HEIC, HIF, TIFF, INSP and PSD.

How it's built

  • Redis holds the index, exiftool reads the metadata, libvips makes the thumbnails, and the server is plain Node with no npm packages.
  • Three agents built it in parallel against a written contract: the Redis schema and the API shape.
  • A "4-second search" turned out to be a hand-written Redis reply parser that re-scanned the whole 95,000-item answer every time a network chunk arrived. Fixed, the same search takes 15 to 26 ms.
  • Each source file is read once: the 1,600-pixel thumbnail is made first and the small one derived from it.
  • The container is built on Debian trixie because the older libheif rejected nearly half of a test set of iPhone 16 photos.

1 / 6

The landing page: cameras grouped by brand. The three cameras and all the pictures here are invented test fixtures.
The landing page: cameras grouped by brand. The three cameras and all the pictures here are invented test fixtures.