Description:

The HTML <details> tag specifies additional details that the user can view or hide on demand.

The <details> tag can used to create an interactive widget that the user can open and close. Any sort of content can be put inside the <details> tag.

The <summary> tag is used to specify a visible heading for the details. The heading can be clicked to view/hide the details.

Example Code:
<details>
<summary>About HTMLPortal</summary>
<p>HTMLPortal is a site dedicated to helping you with HTML.</p>
</details>
Result:
About HTMLPortal

HTMLPortal is a site dedicated to helping you with HTML.

Attributes:
Attribute Definition
open Specifies whether the details should be open (visible to the user) or closed (hidden from the user).
Global Attributes:

The <details> tag also supports the Global Attributes in HTML5

Event Attributes:

The <details> tag also supports the Event Attributes in HTML5