Those who are not using Wordpress or using Wordpress but do not like using the plugins, then they can use this code, I tested the code on my own non Wordpress website and its working fine. Just replace the bold UA code with your own Google Analytics UA.