WooCommerce Distance Pricing - Setup Guide

How to Get a Google Maps API Key for "Calculate Prices Based on Distance for WooCommerce"

Google Cloud Console

Step 1: Access Google Cloud Console

Go to the Google Cloud Console and navigate to the Credentials page.

Select or Create Project

Step 2: Create or Select a Project

Select an existing project or click "Create Project." Name it and enable billing (Google provides free credits, and low usage is free).

Create API Key

Step 3: Generate an API Key

Open the Credentials section, click Create CredentialsAPI Key. Your key will be generated instantly.

Create apikey

Step 4: Configure API Key Restrictions

Application Restriction: Select "Websites" and enter your domain (optional).

Note: Restricting the Domain may sometimes cause issues with Google Maps functionality.

Restrict Keys

Step 5: Enable Required APIs

Ensure only the following APIs are enabled:

  • Directions API
  • Distance Matrix API
  • Geocoding API
  • Maps JavaScript API
  • Places API