Snippets Gallery

Bootstrap 5 Hexagon Photo Gallery Grid

A honeycomb photo gallery that packs seven images into hexagonal cells, with a caption that fades in on hover.

Bootstrap 5 No jQuery Feb 2020 4.3K views

<section class="wdw-stage hive-stage">
  <div class="container hive-container">
    <div class="hive-panel wdw-aurora rounded-5 p-4 p-lg-5">
      <div class="row align-items-center g-4 g-lg-5 position-relative">
        <div class="col-lg-5 text-center text-lg-start">
          <span class="wdw-eyebrow hive-eyebrow">Gallery</span>
          <h2 class="wdw-heading hive-title display-6 mt-2 mb-3">Night sky, in a hive</h2>
          <p class="mb-4 hive-lead">Seven long exposures from mountains, deserts and coastlines, packed into a honeycomb grid that scales to any screen.</p>
          <a href="#" class="btn btn-light rounded-pill px-4">View collection</a>
        </div>
        <div class="col-lg-7">
          <div class="hive" role="group" aria-label="Night sky photo gallery">
            <div class="hive-row"><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1519681393784-d120267933ba?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Alpine night. Milky Way over snowy peaks"><img src="https://images.unsplash.com/photo-1519681393784-d120267933ba?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Alpine night</figcaption></a></figure><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1497733942558-e74c87ef89db?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Valley falls. Waterfall under starry sky"><img src="https://images.unsplash.com/photo-1497733942558-e74c87ef89db?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Valley falls</figcaption></a></figure></div><div class="hive-row"><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1540744276164-9dc898353c7b?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Galactic core. Milky Way arching over a mountain range"><img src="https://images.unsplash.com/photo-1540744276164-9dc898353c7b?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Galactic core</figcaption></a></figure><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1469975692758-66d107a536cb?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Desert dusk. Desert rock formations at dusk"><img src="https://images.unsplash.com/photo-1469975692758-66d107a536cb?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Desert dusk</figcaption></a></figure><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1490845060161-85f9ce08a9f4?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Pine night. Pine tree against a deep blue night"><img src="https://images.unsplash.com/photo-1490845060161-85f9ce08a9f4?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Pine night</figcaption></a></figure></div><div class="hive-row"><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1541673504494-8bcc1a340180?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Canyon sky. Stars above a narrow canyon"><img src="https://images.unsplash.com/photo-1541673504494-8bcc1a340180?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Canyon sky</figcaption></a></figure><figure class="hive-cell"><a href="https://images.unsplash.com/photo-1515937350506-3e7b51a95339?w=1600&q=80&fm=jpg" target="_blank" rel="noopener" aria-label="Open photo: Harbour lights. Coastal town glowing at night"><img src="https://images.unsplash.com/photo-1515937350506-3e7b51a95339?w=500&q=75&fm=jpg" alt="" loading="lazy"><figcaption>Harbour lights</figcaption></a></figure></div>
          </div>
        </div>
      </div>
    </div>
  </div>
</section>

Built on Bootstrap 5.3.8 with plain JavaScript — no jQuery. Supports light and dark mode via data-bs-theme.

Free to use in personal and commercial projects under the MIT license.