To add Google Analytics to a website, one must sign up for a Google Analytics account and obtain a tracking ID. This tracking ID is then copied into a Google Analytics script that gets pasted in the website's HTML code between the <head> tags. Once installed, Google Analytics provides insights into website traffic such as the number of visitors, their locations, time on site, pages viewed, and more. It also allows users to set goals and compare metrics over time to better understand website usage and performance.