| Rule ID | links/tel-mailto |
| Category | Links |
| Scope | Per-page |
| Severity | info |
| Weight | 2/10 |
What it detects
- Invalid tel: links — phone numbers missing digits or too short
- Invalid mailto: links — email addresses missing
@or. - Tel href/text mismatch — the phone number in the
hrefdoesn’t match the displayed text (e.g.<a href="tel:+15551234567">+15559876543</a>). Comparison is formatting-insensitive and allows omitted country codes. - Mailto href/text mismatch — the email in the
hrefdoesn’t match the displayed text (e.g.<a href="mailto:sales@example.com">support@example.com</a>). Comparison is case-insensitive and ignores query parameters.
Solution
Tel links should use format: tel:+1234567890 (E.164 format preferred, no spaces/dashes). Mailto links should have valid email format: mailto:user@example.com. You can add subject and body parameters: mailto:user@example.com?subject=Hi&body=Hello. Invalid formats may not work on all devices. Ensure the displayed text matches the href — a mismatched phone number or email misleads users and may dial/email the wrong contact.Enable / Disable
Disable this rule
squirrel.toml
Disable all Links rules
squirrel.toml
Enable only this rule
squirrel.toml