Skip to content
ClickJack Test

← Refused to connect

analytics.google.com refused to connect

Why Google Analytics will not load in a frame, and what to do. Headers checked 2026-11-30.

The Google Analytics interface cannot be embedded. To show analytics on another page, build a Looker Studio report from your Google Analytics data and embed that report.

What the site sends

Framing header
X-Frame-Options: DENY
Checked URL
https://analytics.google.com/analytics/web/
Checked on
2026-11-30

Test it live →

Why it happens

analytics.google.com sends X-Frame-Options: DENY, so the browser blocks it in every frame.

Fix it if you are embedding Google Analytics

Embed a Looker Studio report

Create a report in Looker Studio with the Google Analytics connector. Open File, then Embed report, click Enable embedding, keep Embed Code selected, and copy the code. If the report is shared publicly, anyone on your page can see it. If it is shared with specific people, only they can, and they must be signed in to a Google account.

Build your own view with the Data API

For a custom dashboard, query the Google Analytics Data API from your server and draw the charts yourself.

If you only see the error

A page tried to show Google Analytics inside a frame. Open analytics.google.com in its own tab.

Being signed in to more than one Google account is a common cause. Google may not know which account the frame should use, and can fall back to your default account. If that account cannot open the file, the frame cannot show it. Open the page in a private window and sign in with only the account that has access. To fix it for good, sign out of every Google account, then sign in first with the one you need: in many cases Google treats the first account you sign in with as the default.

FAQ

Why does the normal Looker Studio link also refuse to connect?

In our check, a lookerstudio.google.com/reporting/... URL sent X-Frame-Options: DENY and frame-ancestors 'none', while the embed URL sent neither. Use the code from Embed report, not the address bar link.

Check your headers

See whether a site sends X-Frame-Options or CSP frame-ancestors, and what browsers will do with them.