HTML Tag Reference - HTML tag <figure>

A figure is a unit of content, optionally with a caption.

The figure element can optionally contain a figcaption element. <figcaption> marks a caption for the figure.

Add caption to an image

    <img alt="Bar chart" 
              Website analytics

Adding caption for more than one image

  <img alt="chart format" src="october.jpg" /> 
  <img alt="chart format" src="november.jpg" /> 
  <img alt="chart format" src="december.jpg" /> 
    website analytics 

Browser compatibility

<figure> Yes Yes Yes Yes Yes

What's new in HTML5

The <figure> tag is new in HTML5.

Global Attributes

The <figure> tag supports the Global Attributes in HTML.

Event Attributes

The <figure> tag supports the Event Attributes in HTML.

Default CSS Settings

figure { 
    display: block;
    margin-top: 1em;
    margin-bottom: 1em;
    margin-left: 40px;
    margin-right: 40px;


A demo showing how to use <figure> tag.

        <figcaption>Listing 1. Caption text</figcaption> 
           This is the content of the figure. 
</body> <!-- w  ww. j a va 2 s.c  o m-->

Click to view the demo