I always thought the Google search algorithm was based on many times people click on the website and links to the website. So if it's near the top, a lot of people are clicking on it or to it, at least more than the ones below it.
Why people are doing so is up to the imagination... :)