A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://www.geeksforgeeks.org/html/html5-figcaption-tag/ below:

HTML figcaption Tag - GeeksforGeeks

HTML figcaption Tag

Last Updated : 11 Jul, 2025

The <figcaption> tag in HTML is used to provide a caption or description for a <figure> element.

HTML
<!DOCTYPE html>
<html>

<body>
  <figure>
    <img src="https://media.geeksforgeeks.org/gfg-gg-logo.svg" 
         alt="gfglogo">
    <figcaption>
      GFG logo
    </figcaption>
  </figure>
</body>

</html>
Syntax:
<figure>
  <img src="image.jpg" alt="Description of the image">
  <figcaption>This is the caption or description of the image.</figcaption>
</figure>

Note: This tag is new in HTML5. The <figcaption> tag also supports the Global Attributes and Event Attributes in HTML.

More Example: HTML
<!DOCTYPE html>
<html>

<head>
  <style>
    figure {
      text-align: center;
      margin: 20px;
    }

    figcaption {
      font-style: italic;
      color: #555;
      margin-top: 5px;
    }
  </style>
</head>

<body>
  <figure>
    <img src="https://media.geeksforgeeks.org/wp-content/uploads/20241127115934034573/lack.jpg"
      alt="A beautiful landscape with mountains and a lake" width="200">
    <figcaption>
      A stunning view of the mountains reflecting in the lake at sunset.
    </figcaption>
  </figure>

  <figure>
    <img src="https://media.geeksforgeeks.org/wp-content/uploads/20241127115934261155/forest.jpg"
      alt="A serene forest with tall trees and sunlight filtering through" width="200">
    <figcaption>
      A tranquil forest scene with sunlight streaming through the trees.
    </figcaption>
  </figure>
</body>

</html>


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4