My question is not about people who are proficient in hacking. I am wondering about websites run by acquaintances or friends of friends, who can use website analytics services provided by the website hosts for business purposes. They may innocently enough decide one day that they want to look up how many visitors viewed their pages, the IP address that visited their site, the location, the service provider of the visitor, the entry and exit pages, the search engine query used to enter the website, etc. While they are viewing, their curiosity may be piqued, and they may attempt to identify a visitor based on the provided information. Then they may decide to stalk the visitor's movements, and may for example try to identify comments or user feedback left by the visitor. The visitor always wanted to remain anonymous, but risks their identity being revealed.
What precautions can be taken before the fact to protect from such an eventuality while retaining complete funcionality? I realize this may be a pretty broad question, because what is tracked by common site tracking services can vary, and the potential concerns of a visitor trying to be anonymous vary greatly too. But I would assume that the ability of a determined hacker far outpaces the reaches of a tech novice using a web analaytics. So maybe some measure input can be contributed if we were to consider granting a visitor the maximal protection from identification in these circumstances.
Of course using proxies, Tor, etc. would be great suggestions. But is that enough against web analytics tools? For example, would enabling scripts to run in Tor in order to view an ordinary video or youtube hosted on a regular site betray the IP address of the viewer, or is the vulnerability caused by enabling scripts in Tor beyond the capabilities of prevalent analytics services? Another example: As far as I know, Facebook doesn't currently allow for tracking. But hypothetically how would it be possible to retain anonymity from shared posts, photos and videos viewed if it some day would become possible or even retroactively viewable?