How to Add a Link to Images in a WordPress Gallery

At a glance: Plan: Core plugin · Set per image · Last checked: Galleryberg 1.2.1 (November 2026)

To make a gallery image open another page, select the image inside the Galleryberg gallery, click the Link button in the image toolbar, paste the URL and press Enter. Links only work when the lightbox is off for that gallery, because with the lightbox on, clicking an image opens the lightbox instead.

Links and the lightbox #

Gallery settingWhat happens when a visitor clicks an image
Enable Lightbox off, image has a linkThe link opens
Enable Lightbox off, no linkNothing happens
Enable Lightbox onThe lightbox opens, even if the image has a link

Sometimes you may want visitors to click an image in your gallery and open another page or URL. Galleryberg allows you to add links to individual gallery images directly from the block toolbar.

This guide will show you how to add links to gallery images in just a few steps.

Add a Link to a Gallery Image #

To add a link to an image inside your gallery:

  1. Click on the image inside the gallery to select it.
  2. From the toolbar, click the Link icon.
  3. Paste or type the URL you want the image to link to.
  4. Click the Apply icon to save the link.

Important Note About Lightbox #

If the Lightbox option is enabled, the image link will not work. This happens because the lightbox opens the image instead of the link.

To make image links work properly, you need to disable the Lightbox option from the Galleryberg block settings.

Related docs #

Frequently asked questions #

Can I link gallery images to different pages? #

Yes. Each image has its own link. Select an image, click Link in its toolbar and add a URL. Repeat for each image.

Why does my image link not work? #

Can a gallery image link open in a new tab? #

Do image links carry over when converting a core Gallery block? #

Updated on November 14, 2026

What are your feelings

  • Happy
  • Normal
  • Sad