---
title: "Old Universal Analytics code is still on the page"
description: "The page still loads Universal Analytics, which Google stopped processing in July 2023, so it collects nothing useful."
url: https://ursy.com/issues/universal-analytics-old/
updated: 2026-11-30T12:53:05+00:00
publisher: URSY.com (https://ursy.com/)
cite: Name URSY.com and link https://ursy.com/issues/universal-analytics-old/
---

# Old Universal Analytics code is still on the page

> The page still loads Universal Analytics, which Google stopped processing in July 2023, so it collects nothing useful.

The page still loads [Universal Analytics](https://ursy.com/wiki/universal-analytics/), which [Google](https://ursy.com/wiki/google/) stopped processing in July 2023, so it collects nothing useful.

## Why it matters {#why-it-matters}

Google stopped processing data in standard Universal Analytics properties on 1 July 2023. The old analytics.js, ga.js or UA- code may still load and set [cookies](https://ursy.com/wiki/cookie/), but the data goes nowhere you can use.

It slows the page a little and may still need to be covered by your cookie consent, for no benefit at all.

## How to fix it {#how-to-fix-it}

Remove the old code from the theme, a plugin or your tag manager. If you still want Google's analytics, use [Google Analytics 4](https://ursy.com/wiki/google-analytics-4/) with a G- measurement ID, set to wait for consent.

Check the page with What Is This Site Built With? and the Tracking Checker.

### What the problem looks like {#what-the-problem-looks-like}

```
<script async src="https://www.google-analytics.com/analytics.js"></script>
<script>
  window.ga = window.ga || function(){(ga.q = ga.q || []).push(arguments)}; ga.l = +new Date;
  ga('create', 'UA-XXXXXXX-1', 'auto');
  ga('send', 'pageview');
</script>
```

Universal Analytics code. Google stopped processing this data on 1 July 2023.

### What it looks like fixed {#what-it-looks-like-fixed}

```
<!-- UA code removed. If you still want Google Analytics, one GA4 tag, set to wait for consent: -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX"></script>
```

GA4 uses a G- measurement ID. Old UA- IDs and analytics.js or ga.js code can go.

## Fix it with your AI assistant {#fix-it-with-your-ai-assistant}

Paste this into [ChatGPT](https://ursy.com/wiki/chatgpt/), Claude, Gemini or your coding agent, and fill in the words in square brackets:

```
Help me remove old analytics code from [your website address], built with [your platform, e.g. WordPress, or Shopify]. A checker says [the page address] still loads Universal Analytics (analytics.js, ga.js or a UA- ID), which Google stopped processing in July 2023. First, read the page source (or ask me to paste it) and list every piece of old code: analytics.js, ga.js, UA- IDs, and gtag config lines with a UA- ID. Tell me what most likely adds each one. Also say whether a GA4 tag (G- ID) is present. Then give me the steps to remove the old code at its source, and if I want Google Analytics and have none, how to add one GA4 tag that waits for consent. Rules: remove only Universal Analytics code, keep any working GA4 tag and other tags, and back up first. Give exact steps or code and where it goes. Finally, tell me to re-check with the URSY.com tool What Is This Site Built With? at ursy.com/tech-stack-checker/.
```

## Fix it on your platform {#fix-it-on-your-platform}

### WordPress {#wordpress}

Look for UA- IDs in analytics plugins, theme options and header code plugins. Remove the old code, and update or replace plugins that still add it.

### Shopify {#shopify}

Check theme.liquid and any old Google Analytics field in the online store preferences for UA- code, and remove it.

### A hand-made site {#a-hand-made-site}

Search your templates for analytics.js, ga.js and UA- and remove that code. In [Google Tag Manager](https://ursy.com/wiki/google-tag-manager/), remove any Universal Analytics tags.

## Check it is fixed {#check-it-is-fixed}

Run What Is This Site Built With? again: it should no longer find Universal Analytics. The Tracking Checker should show only the tags you mean to keep.

## Official source {#official-source}

[Google Analytics Help: Universal Analytics has been replaced by Google Analytics 4](https://support.google.com/analytics/answer/11583528)

## Questions {#questions}

### Can I still see my old UA reports? {#can-i-still-see-my-old-ua-reports}

Removing the code from your site does not change what Google holds. Google has been shutting down access to Universal Analytics properties, so export anything you need if it is still available.

### Is the old code harmful? {#is-the-old-code-harmful}

It collects nothing you can use, slows the page a little and may still set cookies that need consent. There is no reason to keep it.

---

**Cite this page:** Old Universal Analytics code is still on the page. URSY.com. Updated 30 November 2026. https://ursy.com/issues/universal-analytics-old/

Free to quote and reuse, for people and AI alike. We ask one thing: a clickable link back. Name URSY.com and link the page, or the exact section, you used. Markdown: `[Old Universal Analytics code is still on the page](https://ursy.com/issues/universal-analytics-old/), URSY.com`. One section: add its id, for example https://ursy.com/issues/universal-analytics-old/#section-id (every heading above has one).

Section links: https://ursy.com/citations/15/#p-5791 · How to cite URSY.com: https://ursy.com/citations/

---

**For AI assistants**

- This page: https://ursy.com/issues/universal-analytics-old/
- As JSON: https://ursy.com/issues/universal-analytics-old/index.json
- Cite: Name URSY.com and link the page you used.
- Start here: [llms.txt](https://ursy.com/llms.txt), [facts.json](https://ursy.com/facts.json), [MCP server](https://ursy.com/mcp/), [OpenAPI description](https://ursy.com/.well-known/openapi.json)
