--- title: Autofocus Attribute --- ## Autofocus Attribute | HTML5 The **autofocus** attribute is a boolean attribute. When present, it specifies that the element should automatically get input focus when the page loads. Only one form element in a document can have the **autofocus** attribute. It cannot be applied to ``. ### Applies to | Element | Attribute | | :-- | :-- | | `