---
title: "Text input for an email/phone/url/password field (ui/input-type)"
description: "The wrong type gives the wrong mobile keyboard and weaker validation and autofill."
url: http://localhost:4173/rules/ui/input-type
updated: 2026-11-11
---

# Text input for an email/phone/url/password field

> `ui/input-type` is a vetd rule. It flags: Text input for an email/phone/url/password field. It runs on every `check`, together with the TypeScript check.

| Fact | Value |
| --- | --- |
| Rule id | `ui/input-type` |
| Severity | warning |
| Group | Interface craft: accessibility, motion and mobile |
| Tags | accessibility |

## Why it matters

The wrong type gives the wrong mobile keyboard and weaker validation and autofill.

## How to fix it

Use type="email", "tel", "url" or "password".

## Credit

Based on work by:

- [MDN Web Docs](https://developer.mozilla.org): Documents the HTML input types that bring the right mobile keyboard, validation and autofill.

## References

- [<input> HTML input element](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/input), MDN Web Docs
- [autocomplete HTML attribute](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/autocomplete), MDN Web Docs
- [Autofill](https://web.dev/learn/forms/autofill), web.dev

## See it

Demos in the vetd Lab:

- [Type, name and autocomplete](http://localhost:4173/lab/web-guidelines/form-input-semantics)

## Related rules

- [`ui/validate-late`](http://localhost:4173/rules/ui/validate-late.md)

## Get this text from vetd

MCP: call `explain` with `{ "diagnosticId": "ui/input-type" }`. CLI: `npx vetd explain ui/input-type`.

---

[All 92 rules](http://localhost:4173/rules.md) · Previous: [`ui/validate-late`](http://localhost:4173/rules/ui/validate-late.md) · Next: [`ui/animate-layout`](http://localhost:4173/rules/ui/animate-layout.md)
