Skip to main content

Restrict a shipping method by postcode and country

Learn how to restrict your shipping to specific postal codes with postal code-based rates. Perfect for local delivery and custom shipping…

Show the correct shipping method for the intended area without accidentally offering it in other countries.

Postcode filters are available in Abicart Plus and Pro. This guide covers shipping methods under Settings → Shipping, independently of Diversity or TPL themes. You need a saved method and a valid tariff for the country. A postcode filter does not replace country mapping, weight conditions or the carrier's actual coverage.

1. Restrict countries first

Open the method and Connect tariff to delivery address. For Sweden-only delivery, select No delivery as the default and also review continent mappings. Then select the intended tariff for Sweden. A worldwide tariff can otherwise make the method available elsewhere even when you only enter a Swedish postcode filter.

The tariff must have a valid fee and cover the cart's weight and currency. Zero can be an intended fee, but no tariff is different from a zero-fee tariff.

2. Open the country's postcode filter

Beside the relevant country, click Add in the postcode column. For an existing filter, choose Edit. Check that you are changing the correct country and shipping method.

frakt-01-1
frakt-02

3. Enter allowed postcodes

Enter one code or pattern per line. Lines are alternatives: a postcode matching any line can pass. In an ordinary allow filter, an empty field means no postcode restriction within that country.

  • 12345 allows that exact postcode.

  • 1234? uses a question mark for exactly one character.

  • 123* uses an asterisk for zero or more characters. It does not ensure the correct national postcode length.

  • 1234[456] allows 12344, 12345 and 12346.

Spaces and hyphens in the customer's postcode are removed for comparison. Use clear patterns suited to the country. Do not enter an asterisk alone when intending to restrict a small area.

frakt-03

4. Save and check boundaries

Click Done in the dialog and save the method. Check checkout with an allowed postcode, a disallowed one and another country. Use the same cart and valid delivery details so other conditions do not mask the result. A missing delivery postcode can prevent a filtered method from appearing until the address is entered.

frakt-04

If a particular existing configuration uses reverse filter logic, matches are exclusions rather than allowed areas. Do not treat that configuration as an ordinary filter; check its current behaviour before opening sales.

If the method is missing or appears too widely

Check Active, the country's tariff, default and continent mappings, fee, weight limits, customer type and any customer group or bulky-item conditions. Check the integration's and checkout's own controls where they select options. The postcode filter does not book transport or prove the carrier can serve the address.

Quick start

  1. Map tariffs to the intended countries and remove unintended worldwide coverage.

  2. Open the correct country's filter.

  3. Enter one exact postcode or checked pattern per line.

  4. Save and check an allowed area, a disallowed area and another country.

Subscription

Postcode filters require Plus or Pro. Ordinary country and tariff mappings are separate from the postcode function and must always be checked.

Red postbox in front of trees and bushes
Did this answer your question?