Add Google analytics code using theme’s function.php
Without using any plugins, you can add Google analytics (plus other scripts) to your website using this simple code. This simple code will go to your functions.php file and you will not need to add any plugins. To double-check if the code is applied or not, simply check the page source and look at the code.
Link to: Downloads