Element.ariaDescription is an instance property that reflects the aria-description attribute. Learn how a description string annotates an element, how it differs from aria-label and aria-describedby, and how to get or set the property from JavaScript—with five examples and try-it labs.
01
Kind
Instance property
02
Type
String
03
Reflects
aria-description
04
Purpose
Annotate / describe
05
Status
Baseline 2024
06
vs describedby
String vs element refs
Fundamentals
Introduction
An accessible name tells users what a control is (“Close”). An accessible description adds longer context—what will happen, a warning, or extra detail.
aria-description stores that longer string on the element itself. ariaDescription is the JavaScript reflection of that attribute.
JavaScript
const el = document.getElementById("close-button");
console.log(el.ariaDescription);
el.ariaDescription = "A different description";
💡
Beginner tip
Keep aria-label (or visible text) short. Put longer help in ariaDescription—or use ariaDescribedByElements when the help text already lives in another element.
Concept
Understanding the Property
MDN: the ariaDescription property of the Element interface reflects the value of the aria-description attribute, which defines a string value that describes or annotates the current element.
Reflected attribute — mirrors aria-description.
Get / set — readable and writable string.
Annotation — extra context beyond the accessible name.
Baseline — newly available since March 2024 (MDN).
Foundation
📝 Syntax
JavaScript
ariaDescription
Value
A string that describes or annotates the element.
Item
Detail
Type
string
Reflects
aria-description
vs name
Description annotates; name identifies
vs aria-describedby
Inline string vs references to other elements
Pattern
📋 Close Button (MDN Shape)
MDN pairs a short aria-label with a longer aria-description on an icon-only close button:
JavaScript
<button
aria-label="Close"
aria-description="A longer description of the function of this element"
id="close-button">
X
</button>
JavaScript
let el = document.getElementById("close-button");
console.log(el.ariaDescription);
// "A longer description of the function of this element"
el.ariaDescription = "A different description";
console.log(el.ariaDescription); // "A different description"
Compare
⚖️ ariaDescription vs ariaDescribedByElements
ariaDescription
ariaDescribedByElements
Value
String on the element
Array of description elements
Best when
Help text is a simple string in script/markup
Help text already exists as DOM nodes
Attribute
aria-description
aria-describedby
Baseline
2024 (newly available)
2025 (newly available)
Cheat Sheet
⚡ Quick Reference
Goal
Code / note
Read
el.ariaDescription
Write
el.ariaDescription = "Help text"
HTML attribute
aria-description="Help text"
Feature-detect
"ariaDescription" in Element.prototype
MDN status
Baseline Newly available (Mar 2024)
Snapshot
🔍 At a Glance
Four facts about Element.ariaDescription.
Kind
get / set
Instance
Type
string
Annotation
Reflects
aria-description
Attribute
Baseline
2024
Newly available
Hands-On
Examples Gallery
Examples follow MDN Element: ariaDescription. Labs use a close button so you can safely read and write the property.
📚 Getting Started
Read the reflected value and follow MDN’s get/set demo.
Example 1 — Read ariaDescription
Log the current description from the close button.
JavaScript
const el = document.getElementById("close-button");
console.log(el.ariaDescription);
// HTML includes: aria-description="A longer description..."
A longer description of the function of this element
How It Works
The property returns the attribute string. If the attribute is missing, many browsers return null.
Example 2 — MDN Get and Set
MDN: read the description, assign a new string, and log again.
JavaScript
let el = document.getElementById("close-button");
console.log(el.ariaDescription);
// "A longer description of the function of this element"
el.ariaDescription = "A different description";
console.log(el.ariaDescription); // "A different description"
{
"fromProperty": "Updated help text",
"fromAttribute": "Updated help text",
"same": true
}
How It Works
Prefer ariaDescription in script; keep the attribute for HTML markup.
Example 5 — Support Snapshot
Feature-detect and remember name vs description.
JavaScript
console.log({
supported: "ariaDescription" in Element.prototype,
tip: "Short name + longer description string",
alt: "Use ariaDescribedByElements when text is in the DOM",
status: "Baseline Newly available (MDN, Mar 2024)"
});
{
"supported": true,
"tip": "Short name + longer description string",
"alt": "Use ariaDescribedByElements when text is in the DOM",
"status": "Baseline Newly available (MDN, Mar 2024)"
}
How It Works
Feature-detect on older engines. On unsupported browsers, fall back to setAttribute("aria-description", …) if you need the attribute.
Applications
🚀 Common Use Cases
Icon-only buttons that need a short name plus longer spoken help.
Destructive actions with a warning string in script.
Dynamic UIs that update help text without creating extra DOM nodes.
Keeping script and markup aligned without manual setAttribute.
Teaching the difference between name, description string, and describedby.
Under the Hood
🔧 How It Works
1
Element has an accessible name
From content, aria-label, labelledby, and so on.
Name
2
Optional aria-description
Add a string that annotates or describes the control.
Declare
3
Script can update ariaDescription
Property writes keep the reflected attribute in sync.
Update
4
✓
Assistive tech can announce both
Name first, then the longer description when appropriate.
Important
📝 Notes
Not Deprecated, Experimental, or Non-standard on MDN (Baseline Newly available, Mar 2024).
Feature-detect on older browsers.
Do not put the short name only in aria-description—use a proper accessible name.
Element.ariaDescription is Baseline Newly available (MDN: across latest browsers since March 2024). Feature-detect on older engines. Logos use the shared browser-image-sprite.png sprite from this project.
✓ Baseline 2024
Element.ariaDescription
String — reflects aria-description annotations.
BaselineNewly available 2024
Google ChromeSupported in current releases — feature-detect older
Yes
Microsoft EdgeSupported in current releases — feature-detect older
Yes
Mozilla FirefoxSupported in current releases — feature-detect older
Yes
Apple SafariSupported in current releases — feature-detect older
Yes
OperaFollow Chromium support
Yes
Internet ExplorerNo ariaDescription IDL — use setAttribute
No
ariaDescriptionBaseline
Bottom line: Use ariaDescription for a string annotation beyond the accessible name. Prefer ariaDescribedByElements when help text already exists in the DOM. Feature-detect on older browsers and fall back to setAttribute if needed.
Wrap Up
Conclusion
ariaDescription reflects aria-description so you can attach a string annotation to an element from JavaScript. Keep names short, descriptions helpful, and prefer element references when the help text already lives in the page.
Prefer describedby when text is already in the DOM
Keep description text concise enough to announce
❌ Don’t
Replace the accessible name with only a description
Duplicate the same text in label and description
Assume every older browser exposes the IDL property
Write essays—AT users hear every word
Confuse this with ariaControlsElements
Summary
Key Takeaways
Knowledge Unlocked
Five things to remember about ariaDescription
Reflected aria-description string that annotates an element.
5
Core concepts
📄01
Get / set
on Element
Kind
📝02
String
annotation text
Type
🔍03
Beyond name
not a replacement
Rule
✅04
Baseline
newly available
Status
🎯05
vs describedby
string vs elements
Compare
❓ Frequently Asked Questions
It reflects the aria-description attribute as a string that describes or annotates the current element—extra help beyond the short accessible name.
No. MDN marks Element.ariaDescription as Baseline 2024 (newly available since March 2024). It is not Deprecated, Experimental, or Non-standard. Feature-detect on older browsers.
aria-label (or visible text) is the accessible name. aria-description is a longer annotation. Keep the name short; put extra context in the description.
aria-description is a plain string on the element. aria-describedby / ariaDescribedByElements point to other elements whose text forms the description. Prefer describedby when the help text already exists in the DOM.
A string. Reading returns the current description (or null if unset in many browsers). Writing updates the reflected aria-description attribute.
Yes. Reading and writing ariaDescription updates the reflected aria-description attribute.
Did you know?
Support for aria-description as an attribute and for the IDL property has improved over time. Always feature-detect ariaDescription and keep a clear accessible name even when a description is present.