<input accesskey=””>

Sharing is caring!

Attribute of
Input As The Fundamental Form Element In HTML: Here's What It Does
What does <input accesskey=""> do?
Defines a keyboard shortcut for the element.

Code Example

<input accesskey="h" type="Submit" onclick="alert('You clicked the submit button.')" value="Click Me">

<kbd>ctrl</kbd> + <kbd>alt</kbd> + <kbd>H</kbd> 
<kbd>alt</kbd> + <kbd>H</kbd> 
<kbd>alt</kbd> + <kbd>shift</kbd> + <kbd>H</kbd>

ctrl + alt + H
alt + H
alt + shift + H

Global Attribute

In earlier versions of HTML, only a handful of elements could take advantage of the accesskey attribute. As of HTML5, accesskey is a global attribute and can be used on any element.

Adam is a technical writer who specializes in developer documentation and tutorials.

Browser Support for accesskey