Media & Embedded Content

HTML <area> Tag

The <area> tag defines an area inside an image map (an image map is an image with clickable areas).

Definition and Usage

The <area> tag defines an area inside an image map (an image map is an image with clickable areas).

Standard Syntax:<area>...</area>

Interactive ExampleRunnable

HTML <area> Example

html
Try it Yourself
Live code demonstration for the <area> tag. Click "Try it Yourself" to edit and experiment in real time.
<div style="font-family: system-ui, sans-serif; padding: 16px; background: #ffffff; border-radius: 8px; border: 1px solid #e2e8f0; color: #0f172a;">
<img src="workplace.jpg" alt="Workplace" usemap="#workmap" width="400" 
    height="379">

<map name="workmap">
  <area shape="rect" 
    coords="34,44,270,350" alt="Computer" href="computer.htm">
  <area 
    shape="rect" coords="290,172,333,250" alt="Phone" href="phone.htm">
  <area 
    shape="circle" coords="337,300,44" alt="Cup of coffee" href="coffee.htm">

    </map>
</div>

Attributes for <area>

11 Supported Attributes
AttributeValuesDefaultDescription
alttextnoneSpecifies an alternate text for the area. Required if the href attribute is present
coordscoordinatesnoneSpecifies the coordinates of the area
downloadfilenamenoneSpecifies that the target will be downloaded when a user clicks on the hyperlink
hrefURLnoneSpecifies the hyperlink target for the area
hreflanglanguage_codenoneSpecifies the language of the target URL
mediamedia querynoneSpecifies what media/device the target URL is optimized for
referrerpolicyno-referrerno-referrer-when-downgradeorigin origin-when-cross-originsame-originstrict-origin-when-cross-originunsafe-urlnoneSpecifies which referrer information to send with the link
relalternate author bookmark help license next nofollow noreferrer prefetch prev search tagnoneSpecifies the relationship between the current document and the target URL
shapedefault rect circle polynoneSpecifies the shape of the area
target_blank _parent _self _top framenamenoneSpecifies where to open the target URL
typemedia_typenoneSpecifies the media type of the target URL
Global Attributes

The <area> tag also supports the standard global attributes in HTML, including class, id, style, title, hidden, and data-*.

HTML Global Attributes Reference →
Event Attributes

The <area> tag supports event attributes in HTML, such as onclick, onmouseover, onfocus, and more.

HTML Event Attributes Reference →

Browser Compatibility

ChromeEdgeFirefoxSafariOpera

More Tags in Media & Embedded Content

View All 123Tags →