HTML button autofocus attribute
Browser Support
Internet Explorer 10, Firefox, Chrome, and Safari support autofocus attribute.
Note: Internet Explorer 9 and earlier versions of IE do not support autofocus attribute.
Definition and Usage
autofocus attribute is a boolean (Boolean) property.
Autofocus attribute specifies when the page is loaded buttons should automatically get focus.
Differences between HTML 4.01 and HTML5
autofocus property is a new property HTML5 <button> tag.
Differences between HTML and XHTML
In XHTML, allowed attribute shorthand, autofocus attribute must be defined as <button autofocus = "autofocus">.
grammar
<button type="button" autofocus>
HTML <button> tag