Restrict Address Autocomplete to Specific Pages
By default, Address Autocomplete loads the Google Maps JavaScript on every page of your site. If you only use autocomplete on specific pages, you should restrict each instance to those pages. This avoids unnecessary script loading on pages where autocomplete is not needed, improving page load times and reducing API usage.
How to set a page restriction
Go to Settings > Address Autocomplete and select the instance you want to configure. In the “Restrict to page” dropdown, select one or more pages where this instance should be active.
You can select multiple pages per instance. The plugin will only load the autocomplete scripts on the selected pages.
One-click integrations
If you are using a one-click integration like WooCommerce, Easy Digital Downloads, LifterLMS, or Paid Memberships Pro, the page restriction is automatically set to the correct page (e.g., the checkout page). You do not need to configure this manually for those integrations.
When to use page restrictions
Page restrictions are recommended any time you are using a custom instance (not a one-click integration). Common examples:
- A contact form that only appears on your “Contact Us” page
- An application form on a specific landing page
- A store locator on a dedicated page