Black Friday Sale
Up to 30% off Acowebs WordPress plugins · Ends 4 Dec
06d05h23m26s
View deals
Hi, How can we help?

Esc to close

Conditional logic based on Country & state

Updated 1 min read

For conditional logic based on Country & state, the values must be country code & state code respectively (not names).
You can refer to these links to add county code and state code.
List of country codes: https://github.com/woocommerce/woocommerce/blob/master/i18n/countries.php
List of state codes: https://github.com/woocommerce/woocommerce/blob/master/i18n/states.php
Here is an example of how you can add conditional logic with the country(same for state).

Here, the Street Address is displayed when the selected Country/Region is IN (which stands for India) Otherwise Street Address will not be shown.

If you are not sure about how to apply conditional logic, please go through our guidelines to get started with conditional logic from here.

Was this article helpful?

Still need help?

Our support team can help with setup, settings and anything these guides don't cover.