Responsive & Customizable Image Lightbox with Pure JS

Category: Javascript , Modal & Popup | June 9, 2017
Views Total: 181 views
Official Page: Go to website
Last Update: June 9, 2017
License: MIT


Responsive & Customizable Image Lightbox with Pure JS


A small and standalone JS lightbox library which allows you to display large images in a fully responsive and customizable popup window.

How to use it:

Add the lightbox.css in the head section and the lightbox.js at the bottom of the document.

<link rel="stylesheet" href="css/lightbox.css">
<script src="js/lightbox.js"></script>

Insert an image/thumbnail into the document and use data-jslghtbx attribute to specify the large version of your image you wish to display in the lightbox.

<img class="jslghtbx-thmb" src="small.jpg" alt="" data-jslghtbx="ibig.jpg">

Initialize the lightbox and we’re done.

var lightbox = new Lightbox();



  • v0.5.6

You Might Be Interested In:

Leave a Reply