• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer

Tips and Tricks HQ

  • Home
  • Projects
    • All Projects
    • Simple WP Shopping Cart
    • WP Express Checkout Plugin
    • Accept Stripe Payments
    • WP Download Monitor
    • Easy HTTPS Redirection
    • WP Security and Firewall Plugin
    • WP eStore Plugin
    • WP Affiliate Platform
    • WP eMember
  • Products
    • All Products
    • Checkout
  • Support
    • Support Portal
    • Customer Only Forum
    • WP eStore Documentation
    • WP Affiliate Software Documentation
    • WP eMember Documentation
  • Contact

WordPress Video Lightbox Plugin – Display Videos and Images in a Fancy Lightbox Overlay

Home » Blog » WordPress Video Lightbox Plugin – Display Videos and Images in a Fancy Lightbox Overlay

Last updated: October 17, 2024

The WordPress Video Lightbox plugin allows you to embed videos on a page using lightbox overlay display similar to the one shown below. This plugin can be used to display images, flash, YouTube, Vimeo, iFrame etc in a lightbox overlay. The embedded videos can be viewed on iPad too.

Click on the image below to see how the video pops over in a lightbox overlay.

Little Background

Previously I was using another plugin to display my Vimeo videos in a lightbox overlay but recently Vimeo changed their video embed code to use HTML5 in an effort to make the videos playable in iPhone and iPad. Unfortunately, the other plugin wasn’t working with this change and I was getting the following error on all my embedded Vimeo videos:

Sorry, this video does not exist

To get around the problem I created this plugin and tweaked the required JQuery library so it works with the new Vimeo video embed code. When you use this plugin to embed videos it will play your YouTube or Vimeo videos on iPhone and iPad too!

Download WP Video Lightbox

Specification
App Category
WordPress Plugin
Software Name
WordPress Video Lightbox
Version
1.8.8
Date Modified
2024-10-17
Operating System
WordPress 6.6
Description
Embed your videos using a fancy lightbox
File Format
application/zip
Download

Download the WP Video Lightbox Plugin from here.

Plugin Compatibility

Works with the latest version of WordPress.

Plugin Requires

Requires WordPress 3.5 or higher.

Plugin Installation

  1. Unzip and Upload the folder ‘wp-video-lightbox’ to the ‘/wp-content/plugins/’ directory.
  2. Activate the plugin through the ‘Plugins’ menu in WordPress.
  3. Follow the instructions in the “Usage” section to start embedding your images, videos etc.

Plugin Usage

Our documentation for this plugin shows the various ways to use this plugin.

  • Check the WP Video Lightbox Plugin Documentation.

How to Turn Off the Related Videos At the End of a YouTube Video

If you do not want to show the “suggested videos” that YouTube shows at the end of a video playback then use the following technique:

Add &rel=0 at the end of the video ID which will turn off the related videos display.

Here is an example shortcode that shows you how to use this:

[video_lightbox_youtube video_id="G7z74BvLWUg&rel=0" width="640" height="480" anchor="click me"]

Alternatively, you can use “rel=false” at the end of the video URL to turn off the the related videos. Here is an example:

[video_lightbox_youtube video_id="G7z74BvLWUg&rel=false" width="640" height="480" anchor="click me"]

Automatically Use Video Thumbnail as Anchor

You can use an extra parameter in the shortcode to automatically generate and use the thumbnail of the YouTube or Vimeo video as the anchor image.

Here is an example usage of the shortcode with auto thumbnail option:

[video_lightbox_youtube video_id="G7z74BvLWUg" width="640" height="480" auto_thumb="1"]

Or the following for Vimeo video:

[video_lightbox_vimeo5 video_id=29417470 width=800 height=450 auto_thumb="1"]

The above shortcode will produce the following anchor image for the embedded video (it takes the thumbnail of the video automatically):

auto youtube video thumbnail

Using an Image as the Anchor of a Video

You can use an image as the anchor of the video (that will trigger the lightbox effect). Enter the image URL in the “anchor” parameter of the shortcode.

Here is an example usage of the shortcode:

[video_lightbox_youtube video_id="G7z74BvLWUg" width="640" height="480" anchor="http://www.yourdomain.com/wp-content/uploads/anchor-image.jpg"]

Make sure to enter a valid image URL for the anchor. You should first enter the anchor image URL in the browser’s address bar to verify that the image loads (that way you know if the image URL is valid or not).

Specifying alt Attribute for Thumbnail Image

You can use the “alt” parameter in the shortcode to specify an alternate text for your thumbnail image. Search Engines read this text description to understand what this image is about.

Here is an example usage of the shortcode with the “alt” parameter:

[video_lightbox_youtube video_id="G7z74BvLWUg" width="640" height="480" anchor="http://www.example.com/images/youtube-thumb.jpg" alt="text that describes this image"]

Specifying a Description for the Video

You can use the “description” parameter in the shortcode to specify a description for the video. The description text will show up below the video in the lightbox window.

Here is an example usage of the shortcode with the “description” parameter:

[video_lightbox_youtube video_id="G7z74BvLWUg" width="640" height="480" description="Test description text for the video"]

How to Enable Privacy-enhanced Mode in a YouTube Video

If you want to enable “privacy-enhanced mode” in a YouTube video, add &nocookie=1 at the end of the video ID.

Below is an example shortcode that shows you how to use this:

[video_lightbox_youtube video_id="G7z74BvLWUg&nocookie=1" width="640" height="480" anchor="click me"]

Check out my projects page for more cool WordPress plugins.

Related Posts

  • WordPress Easy Paypal Payment or Donation Accept Plugin
  • WordPress Plugin for Category Specific RSS feed subscription menu
  • WordPress Affiliate Platform Plugin – Simple Affiliate Program Management Software
  • WP PDF Stamper Plugin – Stamp Your eBooks with Customer Details to Discourage File Sharing

Wordpress Plugin JQuery,  Web Development,  Wordpress,  WordPress Lightbox,  Wordpress Plugin,  WordPress video,  WordPress Video Lightbox,  YouTube

Reader Interactions

Comments (214 responses)

  1. Leslye says:

    Great plugin! I modified it to automatically pull thumbnails from Vimeo and YouTube when anchor=thumb. I can send you the code if you’d like…

  2. admin says:

    @Yong, you set that up in your video hosting site’s preferences. This plugin just shows whatever the video shows.

  3. Yong says:

    Thank you for this great plugin. This is what I exactly was looking for.

    I have a question. Is there any way to turn off showing related videos at the end of playing video?

    Thank you,

  4. Sergiu says:

    Oh, Graham, to change it to autoplay just go into the plugin’s folder, and edit line 109 of wp-video-lightbox.php, you’ll find there $vid_lightbox_autoplay = ‘false’;

    — just change it to TRUE.

  5. Sergiu says:

    Thanks, man! It works like a charm with the latest version of WP (3.0.4)

  6. Graham says:

    Hi,

    Thank you for the awesome plugin. the non-html code works, not just on pages and posts, but in text/html widgets too. Awesome!

    Is there a way to make the video play automatically?

    Thanks in advance,
    Graham

  7. flick says:

    Thank you for this plugin, works well and it’s very clean!
    Perfect for youtube videos

  8. peter@blastec says:

    Very good post, i enjoyed it alot.

  9. admin says:

    DId you specify the height and width in the shortcode? Please post a link to your web page where you have placed this video.

  10. Matt says:

    First of all awesome plugin! It’s working fine but I noticed that the lightbox behind my videos is smaller than the size of my video. It looks kinda weird. The demo video on this page shows your video fitting perfectly inside the black box. Any ideas?

    Thanks!

  11. stephen milne says:

    update:

    im new to wp so not exactly sure what i am doing…..
    i had put some javascript links in the header but by removing them the script work.

    when i put the javascript links in the footer video lightbox still worked…
    so i guess javascript links should go in the footer!

    brilliant script
    thanks

  12. Chase says:

    update: it was my template header.php. I used part of the header in another temp and it is working great. Thanks again for the great work.

  13. Chase says:

    Update: I have used your example code above on a demo page.

    http://brian-mccann.com/2010/12/demo/

    Can you view my source and see if I am missing any coding?
    thanks for help

  14. Chase says:

    The plugin looks great. I am having some problems getting it to work. I have add it to my directory, activated it in plugins, and have tried the short code and the html. When I click on the text is simple directs me to the youtubes website to watch the video instead of opening up the lightbox. Any idea what I am doing wrong?

  15. admin says:

    Image should work as an anchor… I am using the following shortcode to display the video on this page which uses and image as anchor:

    [video_lightbox_youtube video_id=G7z74BvLWUg width=640 height=480 anchor=https://www.tipsandtricks-hq.com/wp-content/uploads/2010/08/wp-video-lightbox-demo.png]

    I have a feeling the image URL you are specifying is resulting a 404? Make sure your image URL is valid.

  16. paul s says:

    REPOST for clarity.

    (I’m using your SHORT CODE method for youtube)

    For me, this only works using ANCHOR TEXT but I sure need to use an IMAGES for the anchor.

    The short PDF instructions state “You can use an image as your anchor too” … but I see no example of that. Should I opt for the longer HTML method? …image url’s aren’t working. Is there another way to insert an image for the anchor?

  17. Dennis "DennisKnows" Marshall says:

    I want this so bad but I use pop up domination and I recently had some problems with J query and popup dom.

    Sucks for me. Im so tempted to test it tho

  18. admin says:

    Did you use the shortcode or the HTML approach?

  19. Matt says:

    Hello, everyone.

    This plugin truly is a life-saver. I was going nuts trying to get HTML5 working with a lightbox effect.

    HOWEVER…now my client wants vimeo, and HTML5. For some reason I can get the HTML5 player working with youtube but not my vimeo movies. And I have definitely checked the box (in my vimeo pro account) to make mobile versions of all my vids.

    Is anyone else having this problem? Or can see something I’m not? Here’s the link: http://www.christiemcmahoncreative.com/tv, and the video in question is on the second page of the slider, called “Breakfast with Frasier”.

    Thanks in advance!

    Matt

  20. JC says:

    Thank you so much! ^^

  21. TedMB says:

    Ahh nevermind. I got it working. Just a note that there’s a typo in your instructions pdf “Plugin Usage Guide”…or maybe it’s just displaying wrong in the mac imageviewer. In the embed flash section example code there’s both an “&” and a “amp;” together. When I removed the “amp;” from the code it worked perfectly. Thanks soo much!

  22. TedMB says:

    Hey this is amazing! I’ve been looking for a way to have the lightbox effect for both images and video at the same time. Thanks!

    One question – I want to use it to post .mov videos but the box doesn’t resize to the video – it just stays at 500x359px. I tried adding &?width=792&height=294 to the end of the .mov filename but no such luck. Any suggestions? Thanks!

  23. ProMomBlogger - RheaBrown.com says:

    I’ve used you awesome products since 2009 and love your customer service, fast response and awesome plugins

    Promomblogger – RheaBrown.com

  24. Kendra says:

    w00t! I’ve been looking everywhere for something like this – this is brilliant!

  25. Lings says:

    Thanks a Lot Buddy ! Your website is worth bookmarking ! Awesome Post !

  26. oyun says:

    @Cameron, it won’t work on a page if it doesn’t filter the shortcodes that wordpress does by default on it’s posts and pages.

  27. admin says:

    @James, yes but you will need to tweak some code. At the moment eStore uses a different lightbox plugin so it has the rel=”lightbox” attached on the product images. You will just have to change the code os it uses the following and that should do the trick:

    rel=”wp-video-lightbox”

  28. admin says:

    @Mike, I personally haven’t tested it but I am pretty sure you will be able to use the .flv file format.

  29. James Pyle says:

    So I broke down and purchased eStore..then I saw this awesome plugin.

    I am wondering if I can implement the lightbox into the eStore? I want when you click on a product image to open the larger image it to use the lightbox.

  30. Mike says:

    Will your plugin display .mp4 or .flv files from my own web server using the HTML format for Flash? The .swf Flash format does not allow for the length of my videos. So, I use mp4 or flv.

    Thanks so much,

    Mike

  31. admin says:

    @Cameron, it won’t work on a page if it doesn’t filter the shortcodes that wordpress does by default on it’s posts and pages.

  32. Jason says:

    Seriously. Amazing. Had been looking all over for precisely this!

  33. Cameron says:

    Any way to get this plugin to work on a wp-ecommerce product listing?
    It works on regular wordpress pages but not in individual product html.

  34. admin says:

    Use the following code to display your video in an overlay:

    <a href="http://www.youtube.com/watch?v=rkRfEJP5pD8" rel="wp-video-lightbox">Click Here</a>

    Obviously change “Click Here” with what ever you want to say or use an Image instead.

  35. Jason West says:

    I attempting to use the HTML method to display video by clicking on the “see what people are saying about IQMAX” at the bottom of the page at the above address.

    I am receiving this error:
    $(“a[rel^=’prettyOverlay’],a[rel^=’prettyPhoto’]”).prettyPhoto is not a function

    I have checked the source code and prettyPhoto seems to be in the right place. I am assuming that I am missing something obvious since I’m new to WordPress.

    This plugin is exactly what my client wants, so any help would be greatly appreciated.

  36. Irwan Nemoto says:

    Thank you so much for this plugin 🙂

  37. admin says:

    A little more information on the issue you are having would help. Which method are you using? What error do you get? what are you trying to achieve with the plugin?

  38. Albert matthews says:

    Ive really been trying to get this plugin to work in the way laid out in the pdf but it just wont allow me to use it ?? why i do not know.

  39. Konstantinos says:

    Nice job!
    Is there any gallery options??
    Thanks!

  40. Ron says:

    wonderful plugin… thanks..:)

  41. zabidi says:

    thanks for plugin….is impossible if there is a video created for the http://www.smugmug.com/

  42. admin says:

    Never tested it so not sure.

  43. Nik says:

    Will this work with WordTube shortcodes?

  44. James says:

    Thanks for this nice video lightbox plugin.

  45. Alan Eames says:

    Hi tipsandtricks guys,

    This is awesome. I’ve made note of where you are so I can come back again and find more neat stuff for my blog.

    This light box is awesome!

    All the best,

    Alan

  46. Corrine says:

    Thanks for this awesome plugin. Now I can embed all my videos using this plugin.

  47. admin says:

    Hi Kim, yeah you should be able to embed any flash videos (see the embedding a flash video in the usage guide)

  48. Kim Doyal - The WordPress Chick says:

    You guys are fabulous!
    So this will work with Amazon S3 videos too?
    Thanks for another great product!

  49. Darren (Green Change) says:

    This is awesome – I’ve been looking for a way to.make video viewable for iPads and iPhones for ages! Thanks so much.

  50. Jennifer says:

    OMG! Thank you so much for this plugin… I have been searching for two days to get a fix for this!

Newer Comments »

Leave a Reply

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

Primary Sidebar

Featured & Popular Articles

Video Answers to Top WordPress QuestionsWordPress Optimization Tips and Tricks for Better Performance and SpeedEssential WordPress Security Tips - Is Your Blog Protected?WordPress Simple PayPal Shopping Cart PluginTop 15 Search Engine Optimization (SEO) Techniques I Forget to DoList of the Best and Must Use WordPress PluginsHow do I Start a Blog and Make Money Online?Good Domain Name Picking Tips for Your Blog SetupFind Out Which WordPress Web Hosting Company Offers the Cheapest and Reliable Web Hosting Solution

Featured WordPress Plugins

WP Express Checkout Plugin
wordpress estore plugin
wordpress membership plugin
wordpress affiliate plugin

Recent Posts

  • How to Use Browser Developer Tools to Inspect Elements and [...]
  • Accept Donations via PayPal from Your WordPress Site Easil [...]
  • Buy Now Button Graphics for eCommerce Websites [...]
  • Subscription Button Graphics for eCommerce Websites [...]
  • Adding PayPal Payment Buttons to Your WordPress Sidebar Ea [...]

Comment & Socialize

  • @Rob, We have just released ...
    - admin
  • I installed the plugin a co ...
    - Rob
  • @Sebastian, We've released ...
    - admin
  • I've used this plugin on a ...
    - Sebastian Djupsjöbacka
  • @John, this plugin doesn't ...
    - admin

Check out our solutions

View our WordPress plugin collection and start using them on your site.

Our WordPress Solutions

Footer

Company

  • About
  • Privacy Policy
  • Terms and Conditions
  • Affiliate Login

Top WordPress Plugins

  • Simple Shopping Cart
  • PayPal Donations
  • WP Express Checkout
  • WP eStore
  • WP eMember

Blogging Tips

  • How to Start a Blog
  • Selecting a Good Domain
  • Cheap WP Hosting
  • WP Video Tutorials
  • Simple SEO Tips

Search


Keep In Touch

Copyright © 2025 | Tips and Tricks HQ