HTML Intro

HTML Intro Quiz

HTML Intro Exercise

HTML Basics

HTML Basic Quiz

HTML Basic Exercise

HTML Advance

HTML Advance Quiz

HTML Advance Exercise

HTML Tags List

HTML Global Attributes

HTML Attributes


HTML autofocus Attribute

HTML autofocus Attribute



The autofocus attribute is a boolean attribute. When present, it specifies that the element should automatically get focused when the page loads.


Used With:-


Elements Attribute
button autofocus
input autofocus
select autofocus
textarea autofocus




Its syntax is:- < element autofocus >

Code Explanation

All Tutorials related to HTML Attributes

All Sections related to HTML