<figure> & <figcaption>
tag
HTML5
<figure> wraps self-contained content like images or diagrams; <figcaption> provides a caption.
Syntax
<figure>\n <img src="img.jpg" alt="...">\n <figcaption>Caption</figcaption>\n</figure>
Example
html
<figure>
<img src="chart.png" alt="Sales chart 2024">
<figcaption>Fig. 1 — Annual sales data for 2024.</figcaption>
</figure>