Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Analytics Event Tracking As Client Side Error Log [closed]

I'm currently using Google Analytics Event Tracking to track user interface interactions in my web application.

Since our system doesn't currently have a way to log client side errors, as a quick fix I've put event tracking code in catch blocks and web service error handlers.

Does anybody else do this? Is it effective, or would you recommend something else?

Thanks

like image 841
Ryu Avatar asked Nov 12 '09 03:11

Ryu


People also ask

Can Google Analytics track errors?

Event Tracking (Behavior > Events) in Google Analytics is the section to list website errors, such as: 400, 401, 403, and 404, and 500 error pages; Form validation errors.

Why is my Google Analytics not showing any data?

You've turned on the User-ID feature in your view settings but haven't configured it. User-ID tracking needs an additional code implementation and if it's not done, your Google Analytics view will contain no data.

Why did Google Analytics stop working?

Another reason why your Google Analytics is not working is that it might be conflicting with another script on your webpage. If you have other scripts running on your website, make sure they don't use the same variables as Google Analytics.


2 Answers

Not a bad idea! Very clever, in fact. The custom tracking tools in Analytics are just that: custom tools that you can use for whatever meets your needs.

Part of me worries that those with Javascript disabled aren't going to get reported to Analytics, but that percentage gets smaller and smaller.

On a related note: you might consider checking out the beta Analytics feature called "Intelligence." You can set up custom reports so if any numbers are abnormally high or low, it'll email you. Could be a nice way to keep an eye on how well your site is working.

An alternative would be to report the error via AJAX that spits out all the error info in an email. It works well enough for lower-traffic applications and doesn't take much to set up.

like image 153
JoshMock Avatar answered Nov 15 '22 21:11

JoshMock


I like it! Since you can add what ever in your tracking script, it's possible to get enogh information regarding the error! Though I would categorize the errors to be able to sort them out from the "real" Google Analytics data.

We do the same in a much simpler way; having some address validation logged in GA as a page view, which can be sorted out in the content drill down.

like image 45
Tubbe Avatar answered Nov 15 '22 22:11

Tubbe