TransWikia.com

Does Google Analytics track 404 page responses as valid page views?

Webmasters Asked on February 18, 2022

I’m interested to know what counts as a valid page view. I would assume a server status code in the 200 range would be valid. And anything 300, 400, 500 related would not be counted.

Can anyone confirm or point me to documentation that confirms this.

(I asked this question too Google but I get too many results on how to set up tracking for 404s. Which I don’t want. Also I couldn’t find it on the documentation, I kept getting results about handling 404 on the Data export api.)

I’m working with a single page application with short lived pages. I can see hits after the page expires which alludes me. I’m not sure how I’m getting hits days or weeks after it expires. Could it be browser caches are still executing the js and triggering a page view. If they are valid page views I should treat them as such in reports.

One Answer

So Stephen was right in the comments. If the tracking snippet is installed it tracks. Thinking about it further it makes sense, it executes client side, it'd be hard for it to retroactively look at the status code of the originally returned html.

Using a chrome plugin DataSlayer I was able to confirm the event is firing.

enter image description here

enter image description here

Answered by Lex on February 18, 2022

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP