Introduction

Take control of your shipping strategy with the Post Code Pro module for Prestashop. Designed to empower merchants, this powerful tool allows you to restrict shipping to specific postcodes—whether you need to define exact locations, partial areas, or even numeric ranges. Perfectly tailor your delivery zones to match your business needs!

Flexible Postcode Restrictions: Set up unique postcode or zip code rules for different shipping carriers and countries. Whether it’s exact matches, numeric ranges, or pattern-based rules, you’re in full control.

Custom Shipping Costs: Go beyond simple restrictions—apply custom shipping fees for specific postcodes.

Postcode Checker Widget: Enhance the customer experience with a sleek, user-friendly widget. Shoppers can instantly check if delivery is available to their area, reducing cart abandonment and boosting satisfaction.

Installation

The installation procedure is very much similar to most other Prestashop modules. No core changes required therefore installation is straight forward, be sure to follow the instructions below to ensure a successful installation.

  • Upload the module folder to your stores {root}/modules folder
  • Once uploaded, login to your Prestashop Back Office and head over to the Modules section
  • Search for the module and click Install
  • After a successful installation, the module configuration screen is presented to you. More details on this in the next section

Configuration

Lets begin by taking a look at the global module configuration before we look at configuring individual products. Open the global module configuration from the module panel below:

Postcode blocker Configuration

After opening the module configuration you should see two tabs; namely Options and Rules.

Options

The options described below affect the general behaviour of the module

[Filter Delivery Options during checkout?]

When this option is enabled, carriers which are not available for delivery to the customer post code will not be displayed during checkout. In the event that no carriers are available at all during checkout, Prestashop will display a message informing the customer that delivery to their address is not possible.

[Show post code checker widget on the homepage?]

When enabled, the post code checker widget which the customer can use to check if delivery is available in their area will be dusplayed on the homepage.

[Allow customer to select Carrier in the post code checker widget]

When enabled the widget will also display a drop down allowing the customer to select which carrier to check the postcode against.

Rules

Under the rules tab we can start setting up up rules which will apply to specific carriers and countries. For each rule we’ll also be able to choose whether we want to block or allow deliveries to the post codes we define for the rule or charge a custom shipping price.

To create a new rule click the New Rule button located in the top right. You’ll see the form below:

[Carrier]

Choose a specific carrier to which the rule will apply to. You can also choose All Carriers to apply the rule to all carriers.

[Country]

Choose the country to which the rule will be applied to.

[Mode]

Choose one of the following options:

Block deliveries to the post codes I define: This will block / disable the carrier associated with the rule if the customer post code matches any of the postcodes you add to this rule.

Allow deliveries to the post codes I define: Same as the above, but will instead only allow deliveries to the post codes you define.

Charge a custom price: This will allow deliveries to the post code you define and allow you to set an option shipping price for the affected post codes.

After saving the form, choose the Add postcode rule from the Postcodes list.

Adding a post code rule

This will present a form with the following options

[Postcode Pattern]

If you wish to match postcodes to a particular pattern you may enter a regular expression here. For example, to match all post codes starting with BB2, enter ^BB2.

[Range Start]

If you wish to apply the rule to a numeric range of post codes you define a start and end range here. For example entering 5000 and 6000 will apply the rule to all post codes including and between these two numbers.

Save the form and the rule has been created. You may create multiple postcode filters for each rule if required. You may also create multiple rules for different carrier and country combinations.

[Price Impact]
If you chose “custom price” for the mode for the post code rule in the previous mode, you can choose the impact type for the price here, select either Add or Subtract to either increase or decrease by the shipping cost by the amount you enter in the next price field. Selected fixed price to override the shipping price completely.

[Price]

The actual price which will be used in combination with the price impact type above to determine the final shipping price for postcodes matchiong the rule.

Import Postcodes

You can also import a list of postcodes using the import action:

Import post codes

This will allow you to upload a list of postcodes or postcode ranges from a simple CSV file. Each row in the Csv file must contain one postcode (or postcode pattern) or ranges
For example:

12445
19900
20000:30000

Widget

As we touched on earlier, the module also includes a widget which can be displayed in the store front. The module provides you with an option to display it on the homepage. However you may display it anywhere on your site.

Custom Widget Placement in Templates

Place the following shortcode in any of your themes’ template files and the widget will be displayed in that location.

{widget name='postcodeblocker' hook='pcb_postcodechecker_widget'}

Cms Pages

To display the widget within a Cms page simply place the following shortcode into the content of your Cms page:

[postcodeblocker]

This concludes the configuration of the module. Carriers should now either be filtered / hidden during checkout if you have chosen to block or white list post codes. If you have chosen to apply custom prices then the carrier cost should change for all configured post codes during checkout.

Get Post / Zip Code Blocker on Prestashop.com

Get Post / Zip Code Blocker on Prestafusion