On this page
What this issue is
Your form has a phone field with a rule that decides whether a number is acceptable. The rule is wrong, so real mobile numbers get an error such as "Invalid phone number". The visitor typed a good number. Your form said no.
Common causes: a regex (a text-matching pattern) written for one country, a fixed length such as exactly 10 digits, rejecting a leading + or 00, rejecting spaces, dashes or brackets, and a built-in field type that only knows national formats.
| Format typed | Why it often fails |
|---|---|
| +44 7911 123456 | Plus sign and spaces not allowed |
| 07911 123456 | Rule expects exactly 10 digits, this has 11 |
| (415) 555-0132 | Brackets and dash not allowed |
| +49 151 23456789 | Rule expects US-style 10 digits |
| 0044 7911 123456 | Double-zero prefix not accepted |
| +353 85 123 4567 | Length or country code not in the allowed list |
Why it costs you leads or sales
The people who hit this are real, interested visitors who got to the end of your form. Many will not retry. They will not email you to say the form is broken either. You see fewer leads and no error in your analytics, because the failure happens in the browser before anything is sent.
Mobile users are hit hardest. Phones autofill numbers in the device's own format, often with a + and spaces, which is exactly what strict rules reject.
Example: illustrative numbers for a form that only accepts 10 plain digits. Real figures depend on your audience.
- Visitor opens formPage loads fine
- Fills in fieldsPhone autofilled as +44 7911 123456
- Phone validationValid number rejected
- Form submittedNever happens
- Lead in CRMNever arrives
The visitor fills in everything correctly, then stops at the phone field.
How to check if your site has it
Prepare a list of formats
Use real-looking numbers for each market you sell to: national with a leading zero, international with
+, with spaces, with dashes, with brackets, and with00prefix.Submit the form once per format
Use a different format each time. Note which ones show an error.
Test on a real phone
Use autofill on iPhone and Android. Autofill often inserts a
+and spaces.Check the page source
Right-click the field, choose Inspect, and look for
pattern=,type="tel",maxlengthorminlength. Search your scripts fortelorphoneand a regex.Check the server side too
If the form passes in the browser but still fails after submit, the server or form plugin has its own rule. Test with the browser's network tab open.
<input type="tel" name="phone" pattern="[0-9]{10}" maxlength="10" required>How to fix it
The safest rule is lenient: allow digits, spaces, dashes, dots, brackets and a leading +, and require between 7 and 15 digits. 15 is the maximum length of an international number. If you need clean data, normalise the number after the visitor submits rather than blocking them.
<input type="tel" name="phone" autocomplete="tel" inputmode="tel" pattern="^\+?[0-9\s().\-]{7,20}$" title="Enter a phone number, for example +44 7911 123456">function isPlausiblePhone(value) {
const allowed = /^\+?[0-9\s().\-]+$/;
if (!allowed.test(value.trim())) return false;
const digits = value.replace(/\D/g, '');
return digits.length >= 7 && digits.length <= 15;
}Find which plugin validates
Open the form in your form plugin (Contact Form 7, Gravity Forms, WPForms, Elementor Forms and others). Check the phone field settings.
Loosen the field
Use the plugin's phone or tel field type and remove any custom regex or fixed length. In Contact Form 7, use the
[tel]tag, which accepts international formats, or remove a custom pattern.Check for extra code
Search your theme and snippets plugin for custom phone validation filters.
Check the theme form
In Online Store > Themes > Edit code, search for
pattern=near the phone input in the form or checkout-related sections.Replace the pattern
Use the lenient pattern above, or remove the pattern attribute.
Check apps
If a form or popup app adds the field, change its phone validation setting in the app.
Use the Telephone input type
Select the field in the Designer and set its type to Telephone. Webflow does not enforce a national format by default.
Remove custom code
Check Page settings and Site settings custom code for scripts that validate the phone field.
Open the form builder
Select the phone field in your form or survey.
Review the field options
Check the phone settings, including country selection, and test with numbers from your target countries. Remove any custom code that adds its own pattern.
Check the field type
In the form settings, make sure the field is a Phone field rather than a short text field with a custom rule.
Check Velo code
If you use Velo, search for custom validation on the phone input and replace it with the digit-count check above.
Use the Phone field
In the form block, use the Phone field type and test with international numbers.
Remove injected code
Check Code Injection for scripts that add a pattern to the phone input.
Fix both client and server
Update the HTML pattern, JavaScript check and server-side rule so they agree. A lenient client rule is useless if the server still rejects the number.
Consider a phone library
Libraries such as libphonenumber (or its JavaScript port) parse numbers per country. Use them to normalise to E.164 format (for example +447911123456) after submission.
Before
- Exactly 10 digits only
- Rejects + and spaces
- Autofill fails
- Vague error message
After
- 7 to 15 digits, common separators allowed
- Accepts + and spaces
- Autofill works
- Error shows an example
How to confirm it's fixed
- Every format in your test list submits without an error
- Autofill on iPhone and Android is accepted
- The lead arrives in your inbox and CRM with the number intact
- Obvious junk such as "abc" or "123" still shows a helpful error
- The fix works on both client and server
- Numbers from each market you sell to have been tested
How to prevent it happening again
- Keep one phone test list with formats for every market you serve
- Re-run it after form plugin, theme or app updates
- Avoid copying regexes from forums without testing them
- Keep client and server rules identical
- Review phone rules when you launch in a new country
- Schedule an automated test of the form
How FunnelGuard handles this
FunnelGuard detects this issue only partly. It runs your lead form on a schedule with a robot visitor and checks that the test submission goes through. But it only checks the test phone number it is set up with. If that number passes your validation, the check passes, even if other valid formats are rejected.
What it does catch: a form that starts rejecting its own test number, for example after a plugin update or a theme change, with a screenshot and a likely cause in one alert. What it does not catch: rejection of other formats, other countries, autofill formats or numbers with a different length.
To cover the rest by hand, keep the test list from this guide and run it after every change to the form, and whenever you add a market. The Free plan includes 1 site and 2 journeys with daily checks and no card, and paid plans have a 3-day free trial.
Questions people ask
Why does my form say invalid phone number for a valid mobile number?
Usually the form uses a pattern written for one country or format. It may expect exactly 10 digits, or reject spaces, brackets or a leading plus sign. Loosen the rule to accept common separators and 7 to 15 digits.
What is the best regex for validating phone numbers?
There is no single perfect regex, because formats vary by country. A safe lenient option is ^\+?[0-9\s().\-]{7,20}$, plus a check that the digit count is between 7 and 15. For strict checks, use a library such as libphonenumber.
How many digits can a valid international phone number have?
An international number can have up to 15 digits, not counting the plus sign. Many national numbers are shorter, often 7 to 11 digits. A rule that fixes the length at 10 will reject many real numbers.
How do I stop phone validation blocking international customers?
Accept a leading plus sign and common separators, and do not fix the length to one country. Add a country selector or use a phone library if you need exact validation. Test with numbers from each country you sell to.
Should I make the phone number field required on my form?
Only if your team really needs to call the lead. Every required field is another place a visitor can fail or give up. If email follow-up is enough, make the phone optional.
Why does phone autofill fail on my form?
Autofill often inserts the number with a plus sign, country code and spaces. If your pattern allows only plain digits, it rejects the autofilled value. Use type="tel" and autocomplete="tel" and allow those characters.
Can FunnelGuard tell me if my phone validation is too strict?
Only partly. FunnelGuard submits your form with its test phone number and alerts you if that number is rejected. It does not try other formats or countries, so test those by hand.
Related issues
- CNV-029Valid email rejected (plus addressing, new TLDs)Fix guide
- CNV-031Required field can be left blank and the form still submitsFix guide
- CNV-032Validation error message not shown, form just does nothingFix guide
- CNV-036Postcode/ZIP validation wrong for a countryFix guide
- CNV-037Client and server validation disagree (passes client, server rejects)Fix guide
- CNV-042Error text is a raw code ('error 422')Fix guide