How to block PO Box shipping and restrict rates by address in Shopify
Updated · SMART Shipping Rates (E-TRADE PARTNER)
You can hide Shopify delivery methods when the shipping address looks like a PO Box, Locked Bag, or Private Bag by matching address-line text. SMART Shipping Rates & Rules does this in Delivery customizations with Shipping address line 1 and Shipping address line 2. Matching is case-insensitive text on what the customer typed. It is not a postal-address validation service. These hide rules do not require Carrier Service.
4.9 · SMART Shipping Rates does this with zones, calculated rates, and delivery customizations.
Try it freeOn this page
- When merchants restrict shipping by address
- What Shopify can and cannot do natively
- Which SMART module to use
- Address operators
- Setup steps in SMART Shipping Rates & Rules
- Worked example: hide parcel shipping for PO Box, keep pickup
- Spellings worth covering
- Tips before you publish
- What this rule cannot do
- Frequently asked questions
Many parcel carriers will not deliver to a PO Box. Couriers need a street they can reach. If Standard shipping still appears for PO Box 123, the order either fails later or your team pays to redirect it. The checkout should hide methods you cannot fulfill to that address style.
SMART matches the typed address lines. It does not look up whether the address is a real, deliverable street. A customer can still type a street that is not serviceable, or misspell PO Box so the rule misses it. Treat this as checkout control, not address verification.
When merchants restrict shipping by address
- Parcel or freight methods cannot deliver to a PO Box, GPO Box, Locked Bag, or Private Bag.
- Store pickup should remain (or become the only option) when the address is a box number.
- Local van delivery should disappear when address line 1 is a box, not a street.
- A method should only show when the address contains a required site name, such as a named campus or warehouse.
What Shopify can and cannot do natively
Shopify collects address line 1, address line 2, city, and postal code. Native shipping zones use country, region, and sometimes postal codes. They do not hide a method because line 1 contains PO Box. You need a delivery customization that reads the address text.
| Need | Native Shopify | SMART |
|---|---|---|
| Hide a method when address contains PO Box | Not available | Delivery customizations, Address condition set |
| Hide a method for selected postcodes | Limited zone setup | Delivery customizations or Shipping rates zones |
| Create a new price for a postcode group | Basic zones | Shipping rates (Carrier Service required) |
| Validate that a PO Box is a real postal box | Not this | Not this. SMART matches typed text only |
Which SMART module to use
Shipping rates zones can match country, city, and postal code. They do not match customer street lines. Origin address lines are the warehouse address, not the customer. For PO Box and other street-text rules, use Delivery customizations.
| Field | Module | Matches |
|---|---|---|
| Shipping address line 1 | Delivery customizations | Customer street or box line, as typed |
| Shipping address line 2 | Delivery customizations | Unit, box, or extra line, as typed |
| Postal code / city | Delivery customizations or Shipping rates | Destination geography |
| Origin address line 1 or 2 | Shipping rates | Fulfillment location, not the customer |
Address operators
Choose the Address & Contact Details condition set when you create the customization. The useful fields are Shipping address line 1 and Shipping address line 2. Matching is case-insensitive.
| Operator | UI label | Use for |
|---|---|---|
| CONTAINS | contains | PO Box, P.O. Box, POBOX, Locked Bag, Private Bag |
| NOT_CONTAINS | doesn't contain | Require a street-style address to keep a method |
| STARTS | starts with | Addresses that begin with a known prefix |
| IS | is | An exact line you already know |
Setup steps in SMART Shipping Rates & Rules
- Write down which existing checkout methods cannot go to a box address (for example Standard shipping and Express). Leave pickup visible if that is the fallback.
- Open Delivery customizations and create a rule.
- Choose Hide specific delivery method(s) and select those parcel methods. Or hide by delivery type if every shipping-type method should disappear.
- Choose the Address & Contact Details condition set.
- Add Shipping address line 1 contains `PO Box` as the first condition group.
- Add more condition groups (OR) for other spellings: `P.O. Box`, `P.O.Box`, `POBOX`, `Locked Bag`, `Private Bag`, `GPO Box`. Repeat the same groups on Shipping address line 2 if customers put the box number on line 2.
- Save, then test in real Shopify checkout. Checkout simulator does not apply delivery customizations.
- Confirm at least one method remains for a PO Box cart (usually pickup), unless you intend to show no methods.
Common mistake: treating this as address validation
contains PO Box only matches text the customer typed. It does not confirm the box exists, and it does not catch every spelling. A customer can type Box 12, Postal Box, or a street that is still undeliverable. Keep pickup or another fallback visible, and do not claim SMART validates addresses.
Worked example: hide parcel shipping for PO Box, keep pickup
A Melbourne store offers Standard shipping, Express, and Store pickup. Couriers will not deliver to a PO Box. Pickup should stay.
- Create a hide rule for Standard shipping and Express.
- Add condition groups so the rule runs when line 1 or line 2 contains PO Box, P.O. Box, POBOX, Locked Bag, or Private Bag.
- Leave Store pickup untouched so a PO Box customer still has a method.
- Optionally rename Store pickup to Store pickup (required for PO Box addresses) with a second customization if you want that wording only for box addresses.
- Checkout with PO Box 88, Collins Street and confirm parcel methods disappear. Checkout with 88 Collins Street and confirm they return.
Spellings worth covering
Customers do not type one format. Start with the rows below, then add any pattern you see in real orders. Matching is case-insensitive, so `po box` and `PO BOX` are the same test.
| Pattern to put in contains | Catches | Watch-out |
|---|---|---|
| PO Box | PO Box 123, PO BOX 123 | Misses P.O. Box unless you add that group |
| P.O. Box | P.O. Box 123, P.O. Box123 | The dots matter; this is a separate group |
| POBOX | POBOX123 | No spaces |
| Locked Bag | Locked Bag 1 | Common in AU and NZ |
| Private Bag | Private Bag 92000 | Common in NZ and AU |
| GPO Box | GPO Box 999 | City general post office boxes |
Do not use a lone contains `Box` rule. That can hide shipping for streets such as Box Hill Road or Box Street.
Tips before you publish
- Put each spelling in its own condition group so the groups act as OR. One group with every spelling ANDed together will never match.
- Cover line 1 and line 2. Some themes put the box number on line 2.
- Test the hard carts: PO Box only, street plus PO Box on line 2, Locked Bag, and a normal street.
- If you also need metro versus remote prices, that is postal targeting, not address-line matching. See postcode rates, UK Highlands and Islands, Australia remote postcodes, and New Zealand rural delivery.
- For pickup and local delivery visibility more broadly, see hide pickup and local delivery.
Hide undeliverable methods when the address is a PO Box
SMART Shipping Rates & Rules is rated 4.9 stars across 300+ Shopify App Store reviews.
Try the app free4.9 stars · 300+ reviews
What this rule cannot do
It cannot verify a postal box against a carrier or national address file. It cannot geocode a street. It cannot stop a customer from typing a fake street. Calculated Shipping rates still price by zone (country, city, postal code), not by street text. Use hide rules for address-line control, and zones for geography.
Frequently asked questions
›Can Shopify hide shipping for PO Box addresses?
Native zones do not read street text. SMART Delivery customizations can hide existing methods when Shipping address line 1 or line 2 contains a PO Box style pattern. This does not require Carrier Service.
›Does SMART validate that a PO Box is real?
No. The rule matches the typed address text, case-insensitively. It is not an address-validation or carrier deliverability check.
›Should I put PO Box rules in Shipping rates?
No. Shipping rates zones match country, city, and postal code. Customer street lines are Delivery customizations fields. Origin address lines are the warehouse, not the customer.
›Can I keep pickup when I hide parcel methods for a PO Box?
Yes. Hide only the methods that cannot deliver to a box. Leave Store pickup (or another fulfillable method) visible so checkout still has an option.
›Why did a PO Box order still see Standard shipping?
The typed line may not include a pattern you listed (for example Box 12 with no PO). Add the spellings you see in orders, cover line 2, and test in real checkout. Checkout simulator does not apply delivery customizations.