Skip to main content

Installing Address Validation for WooCommerce

Add address validation to your WooCommerce store to improve checkout completion rates and ensure accurate shipping information. This guide walks you through signing up for a free trial, installing the plugin, configuring it, and exploring advanced settings.

Overview

Use Address Lookup to enhance your WooCommerce checkout experience. For more details on capabilities and setup, see our Address Lookup guide.

Screenshots

Address Lookup

Add Address Lookup to your checkout address forms-screenshot

Add Address Lookup to your order page-screenshot


Step 1: Sign Up for a Free Trial

To use AddressZen, you'll first need to create an account and get your API key.

  1. If you don't have an account sign up to create a free account.
  2. Navigate to the KEYS section in your account.
  3. Copy your API Key - you'll need this to complete the setup in WooCommerce. It's a string of characters that begins with the letters ak_. On signing up your first key will have a balance of 200 free lookups for testing.

Step 2: Install the WooCommerce Plugin

You have two ways to install the AddressZen plugin for WooCommerce: directly through WordPress or manually.

Method A: Install via WordPress

This is the simplest method to integrate address validation into your WordPress site.

  1. Log in to your WordPress Admin Dashboard.
  2. Go to Plugins > Add New.
  3. Search for "AddressZen" and click Install Now.
  4. After installation, click Activate.

Method B: Install Manually

  1. Download the AddressZen WooCommerce plugin from GitHub (should be a .zip file) or download the latest version straight from the WordPress Marketplace.
  2. Unzip the release you downloaded.
  3. Log in to your WordPress Admin Dashboard.
  4. Go to Plugins > Add New > Upload Plugin.
  5. Click Choose File and select "AddressZen" from the file you downloaded.
  6. Click Install Now, then Activate.

Developer Note: If you're familiar with FTP, you can also upload the unzipped plugin folder directly to your /wp-content/plugins/ directory. This method is useful for servers with file upload limitations or when you need to modify plugin files before activation.


Step 3: Configure the Plugin

Once the plugin is installed, it's time to configure it.

  1. In your WordPress Admin, go to WooCommerce > Settings.
  2. Click on the Integration tab, and then select "AddressZen".
  3. Make sure the plugin is activated. The box Enabled should be ticked.
  4. Enter your API Key (the one you copied when signing up) in the designated field. You can always find the API Key under KEYS in your AddressZen account.
tip

Give the key a specific name, so it's clear what it's used for in case you need to create more keys, e.g. shipping address.

API Key Security Settings

For enhanced security and usage control, you can configure additional settings in your AddressZen account:

  • Daily lookup limits: Prevent excessive usage
  • URL restrictions: Limit where your key can be used
  • IP whitelisting: Restrict usage to specific IP addresses

Learn more in our API Key Settings documentation.

  1. Enable Address Lookup by ticking the checkbox. If you are unsure about the best setup, read our Address Lookup guide.
  2. Click Save Changes.

Configuring settings-screenshot


Advanced Configuration Options

Optional Settings

The following settings are optional and can be adjusted to suit your specific requirements. |

Configuring advanced settings-screenshot

Make any necessary changes, and don't forget to Save.

For developers who need additional control over the plugin's behavior, advanced JSON configuration options are available.

SettingDescriptionFormatDocumentation
Address Autocomplete Configuration OverrideJSON configuration to override Address Lookup defaultsValid JSON objectAddress Lookup docs

Example Configuration Override

{
"defaultCountry": "USA",
"detectCountry": false,
"hideToolbar": true
}

Warning: Be careful when modifying these settings, as invalid JSON will prevent address validation from functioning correctly. Always validate your JSON using a JSON validator before saving.


Step 4: Test the Integration

To make sure the address verification works:

  1. Go to your WooCommerce checkout page.
  2. Begin typing an address in the address field.
  3. The AddressZen address lookup tool should automatically suggest addresses as you type.

Elementor Integration

If you're using Elementor to design your WooCommerce checkout pages, you can still enable address verification with a few simple steps. This is necessary as Elementor disables the default page actions, which can prevent checkout plugins from functioning correctly. To resolve this issue, follow these steps:

Step 1. Add a PHP snippet to your WordPress Site

You can do this either by editing your functions.php file or by using a PHP snippet plugin. The snippet defines a function that reactivates the WooCommerce-specific checkout hooks.

/**
* Re-invokes certain WooCommerce hooks to activate the AddressZen address verification plugin on checkout.
* Requires the shortcode "[do_woocommerce_hooks]" to be added to the checkout page.
*/
add_shortcode("do_woocommerce_hooks", function () {
// Loads JavaScript and CSS assets
do_action("woocommerce_before_checkout_form");
// Injects credentials and initializes above assets
do_action("woocommerce_before_checkout_form");
});

Step 2: Add the Shortcode to Your Custom Checkout Page

On your custom checkout page, include the following shortcode:

[do_woocommerce_hooks]

This will trigger the function you defined in Step 1, enabling the address verification feature. The AddressZen plugin will automatically activate on any standard WooCommerce checkout fields, so no additional setup is required within Elementor itself.

Step 3: Test

Test the address fields in Elementor to ensure the lookup tool works correctly. It should automatically suggest addresses as you type.


Troubleshooting

If you encounter any issues during installation or configuration:

  • Make sure you’ve correctly entered your API key.
  • Check if the plugin is up to date (you can update plugins via the WordPress admin panel).
  • Ensure that your theme or page builder (Elementor, etc.) is compatible with WooCommerce and the AddressZen plugin.
info

If you need support, you can reach out to us on our support page.