Country-specific ranges
configure valid postal code ranges per country (e.g., 110000-110099 for Delhi, 90001-90210 for Los Angeles)
ZIP/PIN Code Validation at Checkout - validate postal codes against configurable country-specific ranges before customers place an order. Ships with pre-loaded ranges for India, US, UK, Canada, Australia, and Europe, a full-featured admin grid, CSV/JSON import-export, and real...
Key Features:
Additional Services
Built-in from day one. No add-ons, no upsell, no licence keys to renew.
configure valid postal code ranges per country (e.g., 110000-110099 for Delhi, 90001-90210 for Los Angeles)
numeric ranges, alphanumeric patterns (UK, Canada), exact-match lists, and regex patterns
India, US, UK, Canada, Australia, and major European countries ready to go
either restrict to serviceable areas or block specific excluded ranges
Zipcode Validation - ZIP/PIN Code Validation at Checkout for Magento 2. Panth Zipcode Validation validates ZIP/PIN codes at Magento 2 checkout against configurable country-specific ranges. Pre-loaded ranges for India, US, UK, Canada, Australia, and Europe. Admin grid, CSV/JSON import-export, real-time AJAX validation. Compatible with Magento 2.4.4 - 2.4.8 and PHP 8.1 - 8.4.
Engineered for magento 2 zipcode validation, pin code validation, postal code validation — ships with sensible defaults, full admin controls, and zero JavaScript bloat. Works identically on Hyva and Luma; passes Adobe MEQP with zero severity-10 violations.
ZIP/PIN Code Validation at Checkout — validate postal codes against configurable country-specific ranges before customers place an order. Ships with pre-loaded ranges for India, US, UK, Canada, Australia, and Europe, a full-featured admin grid, CSV/JSON import-export, and real-time AJAX validation on the storefront.
Panth Zipcode Validation lets merchants restrict checkout to serviceable delivery areas by validating ZIP/PIN codes against configurable country-specific ranges. Out of the box you get pre-loaded range data for India (PIN codes), United States (ZIP codes), United Kingdom (postcodes), Canada, Australia, and major European countries. Admins can extend or override any range through the admin grid, and merchants handling thousands of serviceable pincodes can use CSV/JSON import-export to manage data in bulk. On the storefront, validation runs in real time via AJAX so customers see "out of service area" messages instantly without waiting for full checkout submission.
Whether you're a courier/delivery business limiting to serviceable pincodes in India, a regional retailer restricting shipments to specific US states, or a European merchant validating postcodes per country, Panth Zipcode Validation provides a single configurable engine for all of it.
Get a free quote for your project in 24 hours — custom modules, Hyva themes, performance optimization, M1→M2 migrations, and Adobe Commerce Cloud.
Kishan SavaliyaTop Rated Plus on Upwork 100% Job Success • 10+ Years Magento Experience Adobe Certified • Hyva Specialist |
Panth Infotech AgencyMagento Development Team Custom Modules • Theme Design • Migrations Performance • SEO • Adobe Commerce Cloud |
Visit our website: kishansavaliya.com | Get a quote: kishansavaliya.com/get-quote
Panth\Core\Helper\Theme detectionThe module ships with curated postal code range data for the following countries:
| Country | Format | Coverage |
|---|---|---|
| India | 6-digit PIN codes | All 28 states + 8 union territories |
| United States | 5-digit ZIP codes | All 50 states + DC |
| United Kingdom | Alphanumeric postcodes | England, Scotland, Wales, N. Ireland |
| Canada | Alphanumeric postal codes | All 10 provinces + 3 territories |
| Australia | 4-digit postcodes | All 6 states + 2 territories |
| Germany | 5-digit postleitzahl | Nationwide |
| France | 5-digit code postal | Nationwide |
| Italy | 5-digit CAP | Nationwide |
| Spain | 5-digit código postal | Nationwide |
| Netherlands | Alphanumeric postcodes | Nationwide |
You can enable, disable, override, or extend any country dataset from the admin grid.
| Requirement | Versions Supported |
|---|---|
| Magento Open Source | 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 |
| Adobe Commerce | 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 |
| Adobe Commerce Cloud | 2.4.4 — 2.4.8 |
| PHP | 8.1.x, 8.2.x, 8.3.x, 8.4.x |
| MySQL | 8.0+ |
| MariaDB | 10.4+ |
| Hyva Theme | 1.0+ |
| Luma Theme | Native support |
| Required dependency | mage2kishan/module-core (free) |
composer require mage2kishan/module-zipcode-validation
bin/magento module:enable Panth_Core Panth_ZipcodeValidation
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento setup:static-content:deploy -f
bin/magento cache:flush
app/code/Panth/ZipcodeValidation/Panth_Core is also installed (required dependency)bin/magento module:status Panth_ZipcodeValidation
# Expected output: Module is enabled
After installation, navigate to:
Admin → Panth Infotech → Zipcode Validation
Admin → Stores → Configuration → Panth Extensions → Zipcode Validation
Settings live under Stores → Configuration → Panth Extensions → Zipcode Validation:
| Setting | Default | Description |
|---|---|---|
| Enable Module | Yes | Master toggle for all zipcode validation |
| Validation Mode | Allow-list | Allow-list (only listed ranges accepted) or Block-list (listed ranges rejected) |
| Enabled Countries | India, US, UK, CA, AU | Which country datasets to activate for the current store |
| Real-time AJAX Validation | Yes | Validate postcodes as the customer types at checkout |
| AJAX Debounce (ms) | 400 | Delay before firing AJAX validation request |
| Error Message | "Sorry, we do not deliver to this area." | Default message shown on invalid postcode |
| Block Checkout on Invalid | Yes | Prevent customers from proceeding if postcode is out of range |
| Validate Address Book | Yes | Also validate postcodes when customers save new addresses |
Access the admin grid at Panth Infotech → Zipcode Validation → Ranges:
CSV format:
country_id,range_start,range_end,label,status
IN,110000,110099,Delhi,1
IN,400001,400099,Mumbai,1
US,90001,90210,Los Angeles,1
US,10001,10099,Manhattan,1
JSON format:
[
{"country_id": "IN", "range_start": "110000", "range_end": "110099", "label": "Delhi", "status": 1},
{"country_id": "US", "range_start": "90001", "range_end": "90210", "label": "Los Angeles", "status": 1}
]
Click Export → CSV or Export → JSON from the ranges grid. Current grid filters are respected, so you can export only the rows you care about.
When a customer types a postcode in the shipping address form, the storefront JS debounces keystrokes and fires an AJAX request to the validation endpoint (/panth_zipcode/validate/check). The server responds with either:
{"valid": true} — postcode is in a serviceable range{"valid": false, "message": "Sorry, we do not deliver to this area."} — postcode is invalid for the selected countryThe form shows an inline error under the postcode field and, if Block Checkout on Invalid is enabled, the "Next" / "Place Order" button is disabled until the customer enters a serviceable postcode.
Validation is theme-aware — on Hyva storefronts the module uses Alpine.js, on Luma it uses Knockout.js, detected via Panth\Core\Helper\Theme.
Yes. The module hooks into the core checkout shipping-address step on both Luma (Knockout) and Hyva (Alpine). No checkout rewrites required.
Yes. In configuration, select which countries should be validated. Unlisted countries skip validation entirely (customers from those countries can check out normally).
The global mode setting applies to all countries by default. For per-country logic, use allow-list ranges — any country that has at least one range defined uses allow-list semantics automatically.
Yes, as long as the checkout collects a postcode field in a standard Magento address form. Custom checkout UIs may need minor JS integration.
Yes. The CSV importer processes rows in chunks. For very large imports (100k+), we recommend running via CLI to avoid admin session timeouts.
No. Validation lookups are indexed and cached per country/store view. Typical AJAX response time is under 30ms.
Yes. Ranges can be scoped to website/store view, so different store views can have different serviceable areas.
Yes. The source is on GitHub at github.com/mage2sk/module-zipcode-validation.
| Channel | Contact |
|---|---|
| kishansavaliyakb@gmail.com | |
| Website | kishansavaliya.com |
| +91 84012 70422 | |
| GitHub Issues | github.com/mage2sk/module-zipcode-validation/issues |
| Upwork (Top Rated Plus) | Hire Kishan Savaliya |
| Upwork Agency | Panth Infotech |
Response time: 1-2 business days.
Built and maintained by Kishan Savaliya — kishansavaliya.com — a Top Rated Plus Magento developer on Upwork with 10+ years of eCommerce experience.
Panth Infotech is a Magento 2 development agency specializing in high-quality, security-focused extensions and themes for both Hyva and Luma storefronts. Our extension suite covers SEO, performance, checkout, product presentation, customer engagement, and store management — over 34 modules built to MEQP standards and tested across Magento 2.4.4 to 2.4.8.
Browse the full catalog on the Adobe Commerce Marketplace or Packagist.
Ready to upgrade your Magento 2 checkout?
SEO Keywords: magento 2 zipcode validation, pin code validation, postal code validation, india pincode magento, delivery area validation, magento 2 checkout zipcode, magento 2 serviceable area, magento 2 pincode checker, magento 2 zip code restriction, magento 2 postcode validator, india pincode checkout magento, us zip validation magento, uk postcode checkout, canada postal code magento, australia postcode magento, european postcode validation, magento 2 ajax postcode, real-time zipcode check, magento 2 delivery restriction, courier serviceable pincode, magento 2 shipping restriction by pincode, panth zipcode validation, panth infotech, hire magento developer, top rated plus upwork, kishan savaliya magento, mage2kishan, mage2sk, magento marketplace developer, custom magento development india, magento 2 hyva development, magento 2.4.8 module, php 8.4 magento, magento 2 checkout optimization
| Module Category | Cart & Checkout |
|---|---|
| Best For | All Sizes |
Talk to Kishan directly — written quote, scope and timeline within 24 hours. No sales call.
ZIP/PIN Code Validation at Checkout for Magento 2