This is an experimental technology
Because this technology's specification has not stabilized, check the compatibility table for the proper prefixes to use in various browsers. Also note that the syntax and behavior of an experimental technology is subject to change in future versions of browsers as the spec changes.
Summary
The HTML <details> Element is used as a disclosure widget from which the user can retrieve additional information.
- Content categories Flow content, sectioning root, interactive content, palpable content.
- Permitted content One
<summary>element followed by flow content. - Tag omission None, both the starting and ending tag are mandatory.
- Permitted parent elements Any element that accepts flow content.
- DOM interface
HTMLDetailsElement
Attributes
This element includes the global attributes.
-
open - This Boolean attribute indicates whether the details will be shown to the user on page load. Default is false and so details will be hidden.
Example
<details> <summary>Some details</summary> <p>More info about the details.</p> </details>
Live result
Specifications
| Specification | Status | Comment |
|---|---|---|
| WHATWG HTML Living Standard The definition of '<details>' in that specification. |
Living Standard | |
| HTML5.1 (draft) The definition of '<details>' in that specification. |
Working Draft |
Browser compatibility
| Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
|---|---|---|---|---|---|
| Basic support | 12 | Not supported bug 591737 | Not supported | 15 | 6 |
| Feature | Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
|---|---|---|---|---|---|
| Basic support | 4.0 | Not supported bug 591737 | Not supported | Not supported | Not supported |