phone_form_field
12.0.5, released yesterday by an unverified publisher
Flutter phone input FormField with internationalization, validation, and country selector.
What it does
Provides a FormField widget for international phone number input with formatting, validation, and a built-in country selector supporting multiple navigation styles (pages, dialogs, sheets). It localizes strings and country names into over 30 languages.
AI-written summary of version 12.0.1, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need a form input specifically for international phone numbers.
- You want built-in validation for mobile and fixed-line phone formats.
- You require a country code selector with built-in search and flag display.
Skip it when
- You only need a standard text input without specialized phone formatting or country selection.
- You require features not supported by the underlying phone parsing library.
Strengths
- Built-in localization for 32 languages.
- Flexible presentation options for the country selector (page, dialog, bottom sheet).
- Integrates seamlessly as a standard Flutter FormField supporting autofill and copy-paste.
Weaknesses
- Web platform requires preloading flag assets to prevent flashing.
- Strict dependency on specific Flutter and Dart versions.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 6
Requires adding PhoneFieldLocalization delegates to your MaterialApp for full localization support.
import 'package:phone_form_field/phone_form_field.dart';
PhoneFormField(
validator: PhoneValidator.required(context),
countrySelectorNavigator: const CountrySelectorNavigator.page(),
)Alternatives
Packages that do the same job and could replace phone_form_field.
- flutter_intl_phone_field
International phone number input with country picker, formatting, and validation for 250+ countries.
76Compare - phone_text_field
Flutter plugin for international phone number input, validation, formatting, and country selection.
49Compare - intl_mobile_field
Customized Flutter TextFormField to input international mobile numbers with country codes.
73Compare - intl_phone_field
A customised Flutter TextFormField for inputting international phone numbers with country codes.
50Compare
Works with
Packages commonly used together with phone_form_field: ones it builds on, ones built on it, and its own family.
- intlphone_form_field depends on itA Dart library for internationalization and localization, providing message translation, plural/gender handling, and date/number formatting.
- material_uiphone_form_field depends on itOfficial Flutter Material UI library implementing Google’s Material Design system.
- diacriticphone_form_field depends on itRemoves common accents and diacritical signs from strings.
- phone_numbers_parserphone_form_field depends on itDart library for parsing, validating, and formatting international phone numbers.
- circle_flagsphone_form_field depends on itProvides a CircleFlag widget to display circular country flag SVGs.
- flutter_country_selectorBuilt on phone_form_fieldA country picker widget to select a country, now re-exported from phone_form_field.
- reactive_phone_form_fieldBuilt on phone_form_fieldReactive wrapper for phone_form_field to use with reactive_forms.