Piwik is free and opensource website analytics tool that you can install on a server (just like you would install WordPress or any script). Piwik is based on php and mysql and gives out real time reports.
Although a lot of people use Google Analytics, it depends on what your needs are. Google Analytics is easy to setup, Piwik gives real time data and a whole lot of flexibility.
If you know Php, you can also edit the files to enhance and modify the interface or reporting in any way you want. And since Piwik is installed on your own server (we recommend you install it on a subdomain, like analytics.example.com), there are no requests for external files. This also makes Piwik a lightweight alternative to Google Analytics.
Analytical widgets can be added and removed easily. Outcomes can be presented as bar graphs, pie charts, or plain text. And another great feature that is included in Piwik is embeddable charts. Take some code, put it on your website and there you have a live web analytical chart embedded on your website.
Piwik also has an interesting API that lets users build applications on this platform. The API makes possible a Desktop application that reports analytics data straight to your desktop.