If you ship within the United States, you may want to limit the states you ship your subscription products. This guide will instruct you on how to restrict your shipping based on certain states and how to hide these states from your checkout. This is a two-part process that involves both your Shopify admin and ReCharge Shipping Settings.
Step 1 - Edit shipping zones in Shopify
- In the Shopify Admin, click Settings.
- Select Shipping and then Edit next to your United States shipping zone. If you don't have one already, you will need to create one first.
- Click Edit again next to the United States (x of 62 states).
- Select the states you want to ship to and exclude to restrict shipping.
Step 2 - Adjust ReCharge Shipping settings
- In your ReCharge Dashboard, click the wrench icon and select Shipping.
- Scroll down to Errors and select the setting Display an error if no matching shipping rate is found. This ensures that when customers attempt to purchase in an excluded state, they will be blocked.
Hide non-supported states from the checkout
You can hide any extra states with CSS on the checkout.
On the checkout page, right-click on the state text field, and click Inspect. From the inspection window, you can locate the state and identify the following code for the corresponding state you want to hide from the list.
Under the Settings menu in ReCharge, click Checkout. In the CSS Editor textbox, enter the code and include the state you would like to hide.
select#checkout_shipping_address_province option[value="Alaska"] {
display: none;
}