#328 by installs
Responsive Lightbox & Gallery
The most popular lightbox plugin and responsive gallery builder for WordPress.
- Installs
- 100,000+
- Rating
- 4.9 (2K)
- Updated
- 11 days ago
Seamlessly integrates FancyBox lightbox into your WordPress blog: Upload, activate, and you're done. Additional configuration optional.
| Last updated | August 7, 2026Updated in the last 3 months |
|---|---|
| Tested up to | WordPress 7.0.8Older than WordPress 7.1.4, the current release |
| Needs WordPress | 5.6 or newer |
| Needs PHP | 7.4 or newer |
| First published | February 6, 2009 |
| Support, last two months | 0 of 1 threads resolved (0%) |
4.6 / 5 from 92 reviews
| 5 stars | 76 |
|---|---|
| 4 stars | 6 |
| 3 stars | 2 |
| 2 stars | 1 |
| 1 star | 7 |
FancyBox for WordPress turns the images you already have into a lightbox gallery. Activate it and every image that links to a full-size file opens in an overlay instead of loading a new page — in posts, pages, widgets and the block editor’s gallery blocks, with no shortcodes and nothing to add to your content.
If the defaults suit you, there is nothing to configure.
What you get out of the box
What you can change
Settings live under Settings → Fancybox for WP, split into Appearance, Animations, Behaviour, Galleries and Misc:
The opening of the plugin's own description. The full text, installation notes and changelog are on its WordPress.org page.
Three ways, and they stack:
• Add data-caption to the link for longer or formatted text:
Basic HTML such as <br>, <em> and <a> is allowed. Captions are sanitised before display, so scripts and event handlers are stripped.
Add class="nolightbox" to the link. Links from Envira Gallery and NextGen Gallery are skipped automatically so the two lightboxes do not fight.
Almost always another plugin or theme loading its own copy of FancyBox. Two stylesheets defining the same class names will fight, because FancyBox’s CSS class names are shared.
To check, open your browser’s developer tools, look at the Network tab, and search for fancybox. If you see a .css file from anywhere other than /plugins/fancybox-for-wordpress/, that is the conflict.
Fixed in 3.4.1. Thumbnails added after the page has finished loading — infinite scroll, lazy loading, AJAX filters — are now detected and bound automatically. Update if you are on an older version.
Yes, with a filter. Put this in your theme’s functions.php or a site-specific plugin:
add_filter( 'mfbfw_is_enabled', function ( $enabled ) { return is_page( array( 'portfolio', 'gallery' ) ); } );
Returning false means nothing loads at all — no CSS, no JavaScript. There are also built-in switches for mobile, WooCommerce shop pages and product pages under Behaviour.
Turn on Exclude PDF files under Behaviour and PDF links will open normally.
Note that iOS Safari cannot display a PDF inside an overlay at all. If your visitors are mostly on iPhones or iPads, excluding PDFs is the more reliable choice.
Fixed: The lightbox could collapse to a thin sliver instead of showing the image, and videos played sound with no picture. The plugin’s stylesheet carried a height: auto !important rule that overrode the height FancyBox calculates for each slide. On its own it happened to work, but as soon as a second copy of FancyBox’s CSS was on the page – any theme or plugin bundling its own – the content box collapsed to nothing. The rule was added in 3.2.5 for a problem that no longer exists, and has been removed.




#328 by installs
The most popular lightbox plugin and responsive gallery builder for WordPress.
#427 by installs
A responsive image lightbox for WordPress galleries, WordPress attachments & FooGallery
#77 by installs
Autoptimize speeds up your website by optimizing JS, CSS, images (incl. lazy-load), HTML and Google Fonts, asyncing JS, removing emoji cruft and more.
#147 by installs
Add 50+ shortcodes with live preview for tabs, accordions, buttons, FAQs, sliders and boxes. Works in Block Editor and Classic Editor.
#167 by installs
Serve autogenerated WebP images instead of jpeg/png to browsers that supports WebP.
#257 by installs
Formerly Easy Fancybox. The most popular WordPress lightbox plugin. Simple, fast, and responsive. Opens images, videos, PDFs, and custom popups.
Read from the WordPress.org plugin API on , when WordPress 7.1.4 was the current release. WordPress.org rounds active installs into buckets. These are the directory's figures, not my verdict, and I haven't tested this plugin.