HTML: input type="tel"
The telephone input hints that a field contains a phone number and can offer a phone-friendly keyboard; it does not enforce one universal format.
What you will learn
- How to label a telephone field
- How autocomplete supports users
- Why phone validation needs regional rules
Minimal example
<label for="phone">Phone number</label>
<input id="phone" name="phone" type="tel"
autocomplete="tel" inputmode="tel">Use the field to improve input on phones. If your service has a known region, explain the expected format and normalize the value on the server.
Common mistakes
- Do not assume a client-side pattern fits every country or valid number.
- Keep leading plus signs, spaces, and extensions in mind when designing storage and display.
- Protect phone numbers as personal data and collect only what the service needs.