# Firebase: “The format of the phone number provided is incorrect” (auth/invalid-phone-number)

> Firebase phone sign-in fails with auth/invalid-phone-number: the number is not E.164. Send a plus sign, the country code and the number, no leading 0.

Canonical: https://app369.com/fix/firebase-auth-invalid-phone-number/
Last updated: 2026-11-08

signInWithPhoneNumber, verifyPhoneNumber or the Admin SDK’s createUser fails with auth/invalid-phone-number. Firebase needs the number in international E.164 form, such as +16505553434. A local number like 07911 123456, or a number without the country code, fails.

**Short answer**

Build the full number before you call Firebase: a plus sign, the country code, then the number without its national trunk prefix (usually a leading 0). Parse it with a library such as libphonenumber-js rather than a regex. On the server, pass a clean E.164 string, and use null, not an empty string, to clear a number with updateUser.

## **Why Firebase rejects the number, and the fix**

1. 01 ### **The country code or plus sign is missing**
  > “Please enter the phone number in a format that can be parsed into E.164 format.” [**GitHub, firebase-js-sdk auth error messages**](https://github.com/firebase/firebase-js-sdk/blob/main/packages/auth/src/core/errors.ts) People type their number the way they dial it at home, or type the country code and the trunk 0 together, like +44 07911. Parse the input with the country from a picker and send the E.164 result. Countries differ (Italian landlines keep their 0), which is why a library beats a regex. In Flutter the code is invalid-phone-number, without the auth/ prefix.```
import { parsePhoneNumberFromString } from 'libphonenumber-js';

const parsed = parsePhoneNumberFromString(input, 'GB');
if (!parsed || !parsed.isValid()) return showMessage('Check the phone number.');
await signInWithPhoneNumber(auth, parsed.number, recaptchaVerifier); // +447911123456
```
2. 02 ### **The Admin SDK gets an empty or formatted string**
  > “The provided value for the phoneNumber is invalid. It must be a non-empty E.164 standard compliant identifier string.” [**Firebase, Admin Authentication API errors (auth/invalid-phone-number)**](https://firebase.google.com/docs/auth/admin/errors) createUser and updateUser want a strict E.164 string. Strip spaces, brackets and dashes first. To remove a phone number with updateUser, pass null, not an empty string.
3. 03 ### **Testing with a made-up number**
  > “They will still go through the same validation as a real user's phone number.” [**Firebase, Authenticate with Firebase using a phone number (web)**](https://firebase.google.com/docs/auth/web/phone-auth) A random test number may not be a valid number for its country. Add fictional test numbers with a fixed code in the Firebase console, such as US 555 numbers like +1 650-555-3434, in the same E.164 form.
4. 04 ### **The wrong value reaches the call** An input that is not wired to state, or a masked field that returns its display format, can pass an empty or partial string. Log the exact value just before the call.

Checked against the vendor’s docs on November 8, 2026: [Firebase docs: Admin Authentication API errors](https://firebase.google.com/docs/auth/admin/errors); [Firebase docs: Phone authentication (web)](https://firebase.google.com/docs/auth/web/phone-auth); [firebase-js-sdk: auth error messages](https://github.com/firebase/firebase-js-sdk/blob/main/packages/auth/src/core/errors.ts).

## **Rather hand it over?**

Fixed scope, fixed price, paid upfront. The work happens in writing; no call needed.

- [from $450**App Fix Ticket**One reproducible bug in an existing mobile or web app, diagnosed and fixed.**See scope and start**](https://app369.com/fixed-price/flutter-firebase-bug-fix/)
- [from $450**AI-Built App Rescue**A Lovable, Bolt or Cursor app checked end to end in 3 days, then its worst problems fixed at a fixed price.****No issues worth fixing, no charge.**** If the Launch Check finds nothing rated medium or higher, Simon refunds the full $450. You keep the report either way. This applies to the first 10 Launch Checks bought after October 30, 2026.**See scope and start**](https://app369.com/fixed-price/ai-app-rescue/)

Related: [**Firebase phone auth invalid-app-credential**](https://app369.com/fix/firebase-phone-auth-invalid-app-credential/) · [**Firebase auth/too-many-requests**](https://app369.com/fix/firebase-auth-too-many-requests/) · [**Firebase auth/invalid-email**](https://app369.com/fix/firebase-auth-invalid-email/) · [**Firebase auth/invalid-action-code**](https://app369.com/fix/firebase-auth-invalid-action-code/)

Questions

## **More on this error**

<details>

<summary>**What does E.164 look like? **+</summary>

A plus sign, the country code, then the subscriber number with its area code, with no spaces and no national trunk prefix. For example +16505553434 for a US number.

</details>

<details>

<summary>**Do spaces or dashes break it? **+</summary>

Firebase’s own error text says the number must be parseable into E.164, and the Admin SDK requires a strict E.164 string. Send a plus sign and digits only.

</details>

<details>

<summary>**Can you fix it for me? **+</summary>

If one bug is the whole problem, the App Fix Ticket covers it: a written diagnosis first, then the fix. If the app has more going on, the Launch Check is a written check of the whole app. Each issue found is rated critical, high, medium or low, with where it is and how it was confirmed. No issues worth fixing, no charge. If the Launch Check finds nothing rated medium or higher, Simon refunds the full $450. You keep the report either way. This applies to the first 10 Launch Checks bought after October 30, 2026.

</details>

A different error?

## **Describe it and get a written quote**

Send the error and what you were doing. You get a written scope, a fixed price and a timeline; Simon replies by email, usually within one business day.

[**Describe your problem **→](https://app369.com/contact/) [**All fixes**](https://app369.com/fix/)