When you enter some search query in the search engine, you get list of websites in the result related to that query. User only click and open that websites that are at the top of the list. Do you know why some websites get high rank and on the top of the search result? Its because of powerful marketing technique which is called SEO ( Search Engine Optimization).
Its the Process of getting traffic from search engines and to get more and more traffic from search engine against a query, your website must be highly seo optimized so that it appear on the first page or at the top of the search result. To get your website at the top you need to know how search engine works. All Search engine have different algorithm to rank and to make list of top websites.
The first basic thing that you need to know to learn SEO is, how search engine works. Its confirm that search engine is not a human, so search engine views a page very differently. You put a lot of animations, a lot of flash objects to make beautiful website, but Search engine does not view the beauty of websites. Search engine crawl a website and checks its textual data to estimate what a site is about. Search engine performs different actions to show the search result. It crawls a website, index a website, process a website, calculate the relevancy and retrieves the result.
Search Engine using crawler or spider crawl the websites and indexes pages one by one. Note one thing here, crawler is the main software that gets your website and checks the links and newely added pages or any updation. Then website is indexed. It means data about website (text on the page, title, description, keywords) are stored in a large database. When search is performed, search engine calculates the relevancy of searched keywords with indexed pages using some algorithm and at the end search result sorted as most relevant to least relevant is returned.
Note one thing here, Every search engine has its own algorithm to find relevancy, thats why each search engine returns different search result for same query.