GitPedia

PhotoSwipe

JavaScript image gallery for mobile and desktop, modular, framework independent

From dimsemenov·Updated June 16, 2026·View on GitHub·

**FEEDBACK NEEDED** I am developing the new version - PhotoSwipe v6, please [read about upcoming changes and leave feedback](https://github.com/dimsemenov/PhotoSwipe/discussions/2170). The project is written primarily in JavaScript, distributed under the MIT License license, first published in 2011. It has gained significant community traction with 25,201 stars and 3,272 forks on GitHub. Key topics include: gallery, image, javascript, lightbox.

Latest release: v5.4.4
May 24, 2024View Changelog →

FEEDBACK NEEDED I am developing the new version - PhotoSwipe v6, please read about upcoming changes and leave feedback.

PhotoSwipe v5 — JavaScript image gallery and lightbox

Demo | Documentation

Sponsor via OpenCollective
Follow on Twitter

Repo structure

  • dist/ - main JS and CSS
  • src/ - source JS and CSS.
    • src/js/photoswipe.js - entry for PhotoSwipe Core.
    • src/js/lightbox/lightbox.js - entry for PhotoSwipe Lightbox.
  • docs/ - documentation markdown files.
  • demo-docs-website/ - website with documentation, demos and manual tests.
  • build/ - rollup build config.

To build JS and CSS in dist/ directory, run npm run build.

To run the demo website and automatically rebuild files during development, run npm install in demo-docs-website/ and npm run watch in the root directory.

Older versions

Documentation for the old version (v4) can be found here and the code for 4.1.3 is here.

Stand With Ukraine


This project is tested with BrowserStack.

Contributors

Showing top 12 contributors by commit count.

View all contributors on GitHub →

This article is auto-generated from dimsemenov/PhotoSwipe via the GitHub API.Last fetched: 6/16/2026