Google Analytics - Getting raw data logs
since we're supposed to answer the original question, there is no way to get actual raw Google Analytics logs other than by duplicating the server call system.
In other words, you need to use a modified copy of the analytics.js script to point to a hosted webserver that can collect server calls.
Long story short, you want your site to capture hits to http://www.yourdatacollectionserver.com/collect?v=1&t=pageview[...] instead of http://www.google-analytics.com/collect?v=1&t=pageview[...]
This is easily deployed using a tag manager such as Google's GTM, along with normal Google Analytics tags.
That will effectively create log entries in your web server which you can process using an ETL or Snowplow or Splunk or your favorite Python/perl/Ruby text parsing engine.
It is then up to you to process the actual raw logs into something manageable. And before you ask, this is not retroactive.
There is no way to get the logs, but ..
The Google Analytics API will let you extract your data out of the system.
There are limits to what you can do:
- you are limited to 7 dimensions and 10 metrics per requests.
- There is also a quota of 10k requests per day per profile (view).
- some of the information you are talking about is not available. Unless the Google Analytics account is set up correctly.
- The data will still be aggregated in one way or another. The smallest time unit available in the API is minutes, so you will not be able to get raw data with timestamps, for example.
It may be good to note that a professional Google Analytics customer could export the raw data from GA to Big Query. Exporting data from BigQuery is free of charge, but storage and query processing is priced based on usage.
Premium analytics at a reasonable price for one flat annual fee of $150,000