Helping people with computers... one answer at a time.
I periodically clean my browser history, but after a while website entries begin to appear in it that I've never actually been to. Some of these sites look quite disturbing, and are not sites that I would ever go to. Why would these entries appear? Do I have spyware or a virus?
Well, certainly viruses or spyware are a possibility - particularly spyware, which often tries to send you off of to all sorts of places that you'd never want to go to.
But in this case, I suspect something more benign. I think your browser or other tools may simply be doing a good job of protecting you.
As I said, spyware often works by forcing your browser to go to places you would never go. Sometimes it intercepts what you're doing and just rudely takes over, other times it opens a new browser window with whatever it's attempting to push.
Similarly, many websites employ pop ups - additional browser windows that open up when you visit the site. These typically contain ads or other material related to the site. Not infrequently they contain ads or material completely unrelated to the site. The site owner is typically getting paid for this type of advertising, or he's using it to promote more of his own ventures.
And thus we have pop up blockers. Pop up blockers were created to prevent pop up windows from happening. Using different techniques, the blockers intercept the requests to create new browser windows and prevent them. Pop up blockers are available as add on products or software, or they're actually built in to some browsers, such Internet Explorer and Firefox.
Pop up blockers insert themselves into the normal processing of web requests, and "kick in" when they detect that a pop up window is being requested. Exactly where depends on the specific blocker and how it operates. It actually gets fairly complicated, since there are so many different ways to create a pop up window. That's why some blockers are more effective than others.
My theory is simply this: a URL that's been requested to open in a pop up window may actually get added to your history before the pop up blocker kills it. You've never seen it, but it's there in the list.
There are other possibilities as well. Some pages on the web that look like a single page are, in fact, a composite of more than one page. What you see as being a single URL may, in fact, have fetched content from several different sites. Depending on how your browser handles these requests, it's possible that these sub-pages could also show up as individual entries in your history. You wouldn't recognize them, because they're not pages that you explicitly went to.
So, all in all, unless someone else is using your computer when you're not looking, I suspect that it's typically a very benign occurrence. However that shouldn't stop you from taking the appropriate precautions to keep your computer safe.