Knowledge base / WordPress

Elementor Google Maps widget not working: how to fix it

Elementor's own Google Maps widget is an iframe, not a JavaScript map. With no key set it uses a keyless Google embed. Once you save a key in Elementor's settings, every widget switches to the Maps Embed API, and that key then has to be right.

How the Elementor widget actually loads the map

The free Google Maps widget has three main settings: Location, Zoom and Height. What it outputs depends on one global setting, the key under Elementor → Settings → Integrations, in the Google Maps Embed API section.

Integrations keyWhat the widget outputsNeeds
EmptyAn iframe from maps.google.com/maps?q=…&output=embedNothing from you
SetAn iframe from google.com/maps/embed/v1/place?key=…A valid key, the Maps Embed API enabled, billing set up

This comes from the widget's source code. It also means the Elementor widget never loads the Maps JavaScript API, so it can't be the source of a duplicate-loader warning or an “Oops! Something went wrong.” grey box. If you see either, another plugin or widget is loading Maps.

When no key is set, the editor shows a notice in the widget panel asking you to add one. The widget still works without it.

How to tell what's wrong

  • A Google error message inside the map frame: the key in Integrations is wrong, restricted, or its project can't use the Maps Embed API.
  • The widget shows nothing at all: the Location field is empty, or a consent plugin removed the iframe.
  • A placeholder asking for consent: a cookie plugin is blocking the iframe until the visitor agrees.
  • A grey box with “Oops! Something went wrong.”: not the Elementor widget. Look for an add-on map widget or a maps plugin using the JavaScript API.
  • Works in the editor, not on the live page: page caching, or a consent plugin that only runs on the front end.

To see which method the page uses, view the page source and search for elementor-custom-embed. The iframe src just after it shows whether a key is in use.

Why it fails

1. A key is set but the Maps Embed API isn't enabled

This is the most common cause after someone adds a key. The key works only if the Maps Embed API is enabled on its Google Cloud project. Enabling the Maps JavaScript API instead doesn't help: they're separate APIs. Elementor's own help page mentions both, but the widget calls the Embed API. If the key has API restrictions, the Maps Embed API must also be in the key's allowed list.

2. The key's website restrictions don't include your domain

Restrict the key to your site, and check every domain the site is served on: www and non-www, and any staging copy you test on.

3. The key was deleted, rotated or belongs to a closed project

A key saved in Integrations years ago by a previous developer may point to a project that no longer has billing, or that was deleted. Google's setup for the Embed API starts with a project that has billing enabled, even though Google says Maps Embed usage is available at no charge.

4. A consent plugin blocks the iframe

Cookie consent plugins commonly replace Google Maps iframes with a placeholder until the visitor accepts. You accepted long ago, so you never see it.

5. An add-on widget, not Elementor's

Add-on packs for Elementor often include an “advanced” map widget built on the Maps JavaScript API, with its own key field in the add-on's settings. These need a Maps JavaScript API key, and they're where duplicate loaders and JavaScript API errors come from.

The fix, step by step

  1. 01Edit the page with Elementor, click the map and check which widget it is. The panel title shows Google Maps for Elementor's own widget. Anything else is an add-on.
  2. 02Check the Location field holds an address Google can find. Try it in Google Maps first.
  3. 03In WordPress admin, go to Elementor → Settings → Integrations and find Google Maps Embed API. Copy the key, or note that it's empty.
  4. 04If you don't need a key, clear the field and save. The widget goes back to the keyless embed. This is a legitimate fix for a simple location map.
  5. 05If you want to keep the key, open Google Cloud Console in the project that owns it. Under APIs & Services, enable the Maps Embed API.
  6. 06Open the key under Credentials. If it has API restrictions, add Maps Embed API. Under website restrictions, add yourdomain.com/* and www.yourdomain.com/*.
  7. 07Confirm the project has an active billing account.
  8. 08Clear your page cache and any CDN cache, then reload the page in a private window.
Embed API errors show inside the frame

Because the widget is an iframe, Google reports key problems inside the map frame rather than as a …MapError line in your page's console. Read the message in the frame: it names the problem, such as an invalid key or an API the project isn't authorised to use.

If the map is an add-on widget

Add-on map widgets use the Maps JavaScript API, so the normal error codes apply. Open the console with F12 and read the error. Typical ones are ApiNotActivatedMapError, RefererNotAllowedMapError and InvalidKeyMapError.

You have included the Google Maps JavaScript API multiple times on this page. This may cause unexpected errors.
Google Maps JavaScript API error: InvalidKeyMapError

If you see the multiple-times warning, two plugins are each loading the API, often with different keys. The Elementor widget isn't one of them. Find the others with the duplicate loader guide, and keep one key in one place. Where page builders store the key lists the usual settings screens.

Consent plugins

  1. 01Open the page in a private window and don't touch the cookie banner. If the map is missing, accept the banner and reload.
  2. 02If the map appears only after consent, open your consent plugin's settings and find its rules for Google Maps or embedded content.
  3. 03Decide whether the map can load before consent. If not, make sure the placeholder explains how to show it. A blank box looks broken.
  4. 04If your optimisation plugin lazy-loads or delays iframes, exclude the map iframe and test again.

Confirm it is fixed

Reload the live page in a private window. The map should render inside the frame with no Google message. Check with and without accepting the consent banner. Then run a scan on the page: it loads it from a clean session and lists the Maps Embed API and Maps JavaScript API requests it saw, which shows whether an add-on is still loading a second copy of Maps.

Common questions

Does the Elementor Google Maps widget need an API key?

No. With the Integrations key empty, the widget uses a keyless Google Maps embed. If you set a key, it switches to the Maps Embed API, and the key then needs that API enabled and a billing account on its project.

Which API should I enable for Elementor's Google Maps widget?

The Maps Embed API. The widget uses an iframe from the Embed API when a key is set, so enabling only the Maps JavaScript API won't fix it.

Is the Google Maps widget in Elementor free?

Yes. The Google Maps widget is part of the free Elementor plugin. Add-on packs offer extra map widgets with multiple markers, and those usually need a Maps JavaScript API key.

Why does my Elementor map show “Oops! Something went wrong.”?

That message comes from the Maps JavaScript API, which Elementor's own widget doesn't use. Look for an add-on map widget, a store locator or a theme feature loading Maps, and check the browser console for the error code.

Check whether this is your error

A scan tells you in about twelve seconds, from a clean session.

Related articles