Google Analytics not reporting on iOS

Hi,

I have successfully activated and integrated the Google Analytics plugin in my app, and It is reporting very well for Android, but nothing from iOS device.

Should I do something to make it work for iOS? or do I just need to wait a few more days?

Thank You

First, have you looked at your device’s console log to see if you’re getting any errors? (Xcode Window->Devices)

If I had to guess, you may not have ATS set in your build.settings. See: https://coronalabs.com/blog/2015/09/17/about-app-transport-security-ats/

Rob

Hi Rob,

I do not get any error from my device.

As for the ATS this is how my NSAppTransportSecurity looks like:

NSAppTransportSecurity = { NSAllowsArbitraryLoads=true, NSExceptionDomains = { ["fbcdn.net"] = { NSIncludesSubdomains = true, NSExceptionRequiresForwardSecrecy = false, }, ["facebook.com"] = { NSIncludesSubdomains = true, NSExceptionRequiresForwardSecrecy = false, }, ["akamaihd.net"] = { NSIncludesSubdomains = true, NSExceptionRequiresForwardSecrecy = false, }, }, },

Thanks

This is the only line regarding Goggle Analytics:

\<Warning\>: INFO: GoogleAnalytics 3.15 -[GAIReachabilityChecker reachabilityFlagsChanged:] (GAIReachabilityChecker.m:159): Reachability flags update: 0X000002

I would recommend trying the sample app with your ID’s and see if it works or not.

https://github.com/coronalabs/plugins-sample-googleAnalytics

Rob

Hi,

I’m trying the plugin but nothing shows on the report both in Android and iOS.

I made a new property to test the sample. Is it because It needs time before being active?

Nothing shows also in the real time overview.

I tried again the plugin on my app with a new Google Analytics ID and It’s always working with Android (even realtime) but nothing from my iPhone.

I’m gonna send it like this and see what happens.

I just installed the sample app on my iPhone, set the trackingID and appName and from “Real Time”->“Events” I see my taps on buttons and objects come in a second or so after I tap them.

If I switch to “Scenes” instead of events, I don’t see any events come in, but I do see scene changes register.

As for the rest of GA’s stats it can take several hours, perhaps the next day for you go see any collected stats.

Here are my values (masked out my real number):

appName = “Test App 1”
trackingID = “UA-12345678-1”

In the GA interface you do have to define a view for the app, but Android and iOS should be using the same view.

Rob

Hi,

yes I will try tomorrow to see if they are coming through. Are you on Android or iOS?

I have an iPhone 4s with iOS 6 on it right now so maybe It’s because It’s an old configuration?

I would also like to ask you if there is a way to see reporting on a state (US states) or city level in Flurry or Google Analytics without bothering Apple during the review (and the user during his installation).

I have the info when doing it on Android because the player is giving permission when installing the app, but I was wondering if It’s possible something similar for iOS users.

Thanks

There is a good chance that iOS 6 maybe too old. I have iOS 9 on the the iPhone I tested with. Flurry just shows data you send it as far as I know. GA does try and figure out the location off the device based on IP address.