Form
URL input
Published on
Description
The URL input provides a text field for entering web addresses. It validates that the value is a properly formatted URL and shows a URL-optimized keyboard on mobile devices.
Example
Accessibility
- Use explicit
<label for="id">association. - Use
autocomplete="url"to enable browser autofill. - Inherit typography for WCAG 1.4.12 compliance.
- Provide hint text describing the expected format (e.g. "https://example.com") via
aria-describedby.
References
- Under-Engineered Text Boxen (opens in new tab) — Adrian Roselli
- My Priority of Methods for Labeling a Control (opens in new tab) — Adrian Roselli
Related
- Text input — for general text
- Email input — for email addresses
Variables
None for input