W3cubDocs

/HTML

input type="ode" (attribute)

The inputmode global attribute is an enumerated attribute that provides a hint as to the type of data that might be entered by the user while editing the element or its contents. It can have the following values:

"none"
No virtual keyboard; this is useful when the application or site implements its own keyboard input control.
"text"
Standard text input keyboard for the user's current locale.
"decimal"
Fractional numeric input keyboard containing the digits and the appropriate separator character for the user's locale (typically either "." or ",").
"numeric"
Numeric input keyboard; all that is needed are the digits 0 through 9.
"tel"
A telephone keypad input, including the digits 0 through 9, the asterisk ("*"), and the pound ("#") key. Form inputs that require a telephone keypad should typically use <input type="tel"> instead.
"search"
A virtual keyboard optimized for search input. For instance, the return key may be re-labeled "Search", and there may be other optimizations.
"email"
A virtual keyboard optimized for entering email addresses; typically this includes the "@" character as well as other optimizations. Form inputs that require email address entry should typically use <input type="email"> instead.
"url"
A keypad optimized for entering URLs. This may have the "/" key more prominently available, for example. Enhanced features could include history access and the like as well. Form inputs that request a URL should typically use <input type="url"> instead.

If this attribute is not set, its default value is "text", indicating that the locale's standard text entry keyboard should be used.

Spec conflict: The WHATWG spec lists inputmode, and modern browsers are working towards supporting it. The W3C HTML 5.2 spec however no longer lists it (i.e. marks it as obsolete). You should consider the WHATWG definition as correct, until a consensus is reached.

Specifications

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support 66 ? No ? 53 No
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support 66 66 ? No No No ?

See also

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/inputmode