Disable the Divi Gallery Module Lightbox

Written by Dan Mossop

The Divi Gallery module allows you to display a collection of images in a grid or slider format. By default, clicking on an image opens it in a lightbox popup. Divi doesn't include a built-in way to disable the lightbox functionality. This guide provides a step-by-step guide on how to disable the Divi gallery module lightbox.

Disable Divi Gallery Lightbox using Divi Booster / Divi Gallery Booster

This section shows you how to turn off the lightbox in the Divi Gallery module using the 'Enable Lightbox' toggle provided by either Divi Gallery Booster or Divi Booster. Once disabled, clicking a gallery image will no longer open a popup or navigate away.

Open the 'Elements' Section in Gallery Settings

With your gallery images already added, open the Gallery module settings. In the module panel, find the section labeled 'Elements' and click on it to expand the available options.

Turn Off 'Enable Lightbox'

Locate the 'Enable Lightbox' setting in the Elements section. Click the toggle to set it to Off (No). This will prevent the lightbox popup from showing when gallery images are clicked.

Save and Publish Your Changes

Once you've turned off the lightbox, save your changes and publish the page so your gallery is updated on the front end.

Confirm the Lightbox Is Disabled

View your page on the front end and try clicking on gallery images. They should no longer open in a popup or link anywhere.

Disable Lightbox on Divi Gallery Modules using Custom CSS

If you don't want to use a plugin, you can disable the lightbox by adding a small CSS snippet directly to the Gallery module. This method prevents clicks on gallery images, keeping the gallery purely visual.

Add a Gallery Module and Select Images

Insert a Gallery module and add your images just as you would normally, using the 'Add Gallery Images' button in the module settings.

Add Custom CSS to Disable Clicks

In the Gallery module settings, open the 'Advanced' tab, then expand the 'Custom CSS' section. Find the 'Gallery Item' field and enter the following CSS:

pointer-events: none;

This code prevents any interactions (such as clicks) on the gallery images, effectively disabling the lightbox.

Publish and Test Your Gallery

After adding the custom CSS, click 'Publish' to save your changes. Visit your page on the front end and hover over a gallery image—your mouse cursor should not change to a hand, and clicking images will no longer trigger the lightbox or any navigation.

Conclusion

With just a quick setting change using Divi Gallery Booster or Divi Booster, or some CSS code, you can easily disable the Divi Gallery module's lightbox popup. Now your gallery images will display without opening in a popup when clicked.

We may earn a commission when you visit links on our website.

Enhance Your Divi Galleries with Divi Gallery Booster

Elevate your image presentations with the Divi Gallery Booster. Unlock advanced options to style your galleries exactly how you envision, enhancing viewer engagement without cumbersome lightbox pop-ups. Perfect for making your site's visual content stand out.

Latest Posts

Customize Lightbox Title Styling in the Divi Gallery Module

Adjust the appearance of the lightbox title that appears when visitors open images from a Divi Gallery to align with your brand and improve readability. Refining the title’s color, size, and weight enhances visual hierarchy, accessibility, and overall polish. In this...

Center the Lightbox Image Count in the Divi Gallery Module

Centering the image count in a gallery lightbox creates a cleaner, more balanced presentation and makes it easier for visitors to see where they are in the image set. This simple visual tweak can enhance readability, especially with larger images and longer captions,...

Style the Divi Gallery Module Lightbox Image Count

Tailor the appearance of the image counter in the Divi Gallery module lightbox to match your brand and improve readability. By customizing the counter’s color and typography, you ensure it displays clearly and suits your design. In this guide we show you how to style...

Customize the Lightbox Image Background Color in the Divi Gallery

Control the color that appears behind your images when users open in the gallery lightbox, including support for semi-transparent hues. This helps improve contrast for transparent images, align the experience with your brand palette, and create a more polished viewing...

About Dan Mossop

Dan is a Scottish-born web developer, now living in Brisbane with his wife and son. He has been sharing tips and helping users with Divi since 2014. He created Divi Booster, the first Divi plugin, and continues to develop it along with 20+ other Divi plugins. Dan has a PhD in Computer Science, a background in web security and likes a lot of stuff, 

0 Comments

Submit a Comment

Comments are manually moderated and approved at the time they are answered. A preview is shown while pending but may disappear if your are cookies cleared - don't worry though, the comment is still in the queue.

Your email address will not be published. Required fields are marked *.

Works with Divi 5

This feature has been tested and confirmed to work with Divi 5.

Works with Divi 4

Gallery Booster

All the Divi Gallery module features you need!

All licenses are lifetime – pay once, use forever.

Divi Booster

Hundreds of new features for Divi!

All licenses are lifetime – pay once, use forever.