Is “View Source” enough to check whether Shopify analytics is installed?

You open View Source, search for your analytics tool, and find nothing.
It is tempting to stop there. Maybe the tracking was never installed. Maybe an app update removed it. Maybe the store has been collecting no data at all.
We nearly reached that conclusion on our own site.
We searched the homepage HTML for our tracking snippet and found nothing. We were close to calling our analytics broken. It was not broken. The tracking key lived in the compiled JavaScript bundle, not in the HTML the server sent first.
That was a useful reminder: View Source answers one narrow question. It shows the first HTML response for that page. It does not show everything that runs after the page loads.
For a Shopify store, it is not enough to prove analytics is installed. It is certainly not enough to prove analytics is working.
What View Source can tell you
View Source can still be useful, especially on an older store.
Search for familiar tracking names such as:
- `gtag()`
- `dataLayer.push()`
- `fbq()`
You may find tracking code added directly to the theme. You may also find old code left behind after a newer pixel was installed.
That matters because duplicate tracking can create confusing reports. One purchase may be counted twice. A tool may receive events from both an old theme script and a newer Shopify pixel.
In under a minute, you can check a storefront page:
1. Open a product page in your browser. 2. Right-click and choose View page source. 3. Search for `gtag`, `dataLayer`, and `fbq`. 4. Write down anything you find before removing it.
Do not treat an empty search as a failed installation. And do not treat a matching script as proof the tracking works.
It only tells you that some text appeared in that page's original HTML.
Why Shopify pixels may not appear in the source
Shopify has a pixel system for tracking customer events.
App pixels run in a Shopify-controlled strict sandbox. Custom pixels run in a lax sandbox iframe. In plain terms, Shopify controls where that code runs instead of placing it as ordinary inline JavaScript in your storefront HTML.
So you can have a working pixel and find no obvious tracking snippet in View Source.
The opposite is also possible. You may find an old snippet in the source, while the current pixel is disconnected, blocked by consent, or failing to send requests.
This is why the Shopify admin is the better starting point.
Start in Customer events
In Shopify admin, go to:
Settings → Customer events
This is where Shopify manages app pixels and custom pixels.
Check whether the pixel you expect is listed. For a custom pixel, look for a Connected status. For an app pixel, remember that the app must be installed and configured before its pixel can load.
This check answers a more useful question than View Source:
Does Shopify know about this pixel and consider it active?
It still does not answer whether events are reaching the analytics service. You need to test that next.
Test the pixel while events happen
Shopify provides Shopify Pixel Helper for checking events in real time.
For an app pixel, Shopify's test path is:
Settings → Customer events → More options next to the app pixel → Test
For a custom pixel, first confirm the pixel is Connected. Then use Pixel Helper to see whether it receives store events and sends data.
Open the test, then visit the store as a customer would. A simple path is enough:
- Open the homepage.
- Open a collection.
- Open a product.
- Add that product to cart.
- Begin checkout if your test setup allows it.
You are looking for actual events as you move through the store. A pixel listed in the admin is configuration. Events appearing during a test are evidence that the configuration is doing something.
Shopify pixels can run across the storefront, checkout, Thank you page, and Order status page. A homepage source check cannot cover all of those places.
That matters most when you are checking purchase tracking. The storefront can look fine while the event you care about only happens after an order.
Check consent before calling a pixel broken
A test can also show that the pixel is waiting for customer consent.
Shopify Pixel Helper may display “Pixel is awaiting consent.” In that case, the absence of an analytics request may be expected. The customer has not given the permission required by your setup.
If you use a third-party consent tool, it needs to sync consent through Shopify's Customer Privacy API. Otherwise, the consent tool and Shopify can disagree about whether tracking should run.
Do not work around this by assuming a pixel should fire before consent. First check how your store has been set up to handle customer privacy.
A useful test is to repeat the same path in two conditions:
- Before making a consent choice.
- After accepting the categories your analytics needs.
If the event appears only after consent, that may be correct behaviour rather than a fault.
Use Network to confirm data leaves the browser
Pixel Helper shows what Shopify receives and what events occur. The browser's Network panel helps answer the next question: did a request reach the analytics endpoint?
Open your browser's Developer Tools, then choose Network. Keep it open while you reload a page or repeat an action such as adding a product to cart.
You will see many requests. That is normal. Filter by a known part of your analytics provider's domain if you know it. Then inspect the requests that appear during the action.
Shopify recommends confirming that requests reach the third-party analytics endpoint.
This is the step that catches a common false positive: a pixel exists, an event appears, but the request does not successfully reach the service meant to receive it.
You do not need to understand every request in the list. Start with one action and one expected request.
For example: load a product page, then see whether a new analytics request appears at the same time. Next, add the product to cart and look again.
Remember that View Source cannot test server pixels
Not all analytics collection happens in the browser.
Shopify distinguishes web pixels from server pixels. Web pixels send events through the customer's browser. Server pixels send events from the app owner's server.
View Source cannot confirm server-side collection. Browser Network tools cannot show every server-to-server request either.
If your setup uses a server pixel, use the tool's own reporting or test method alongside Shopify's pixel settings. Do not expect the storefront HTML to settle the question.
Also, avoid using old Shopify cookies as an installation test. Shopify announced that `_shopify_s` and `_shopify_y` would no longer be set starting January 1, 2026. Searching source or browser storage for those cookie names is not a current way to check whether analytics is installed.
A better five-minute check
If you need a practical answer, use this order:
1. Open Settings → Customer events in Shopify. 2. Confirm the expected app pixel or custom pixel is present. 3. Check that a custom pixel says Connected. 4. Run Shopify Pixel Helper while you browse a product and add it to cart. 5. Check whether consent is holding the pixel back. 6. Open Developer Tools → Network and confirm requests reach the analytics endpoint. 7. Use View Source only to look for legacy theme tracking that could duplicate the newer setup.
This gives you separate answers to separate questions: what is configured, what events fire, what leaves the browser, and whether old code remains.
That is more useful than one empty search box.