It is important to understand how World Wide Web works. In this tutorial, you will learn how the web works in real world.
To access the web pages you generally use tool called "browser" which helps you to see or read web pages. Some of them very popular are Microsoft IE, google chrome, Safari and Firefox etc.
When you type URL of the web site (if you know any) in the browser's address bar it sends a request to the web server (which is physically located somewhere on the internet) with IP address of your machine. The web server accepts your request and sends immediate response to your IP address in the form of HTML document.
This all is made possible by HTTP protocol which is used to communicate between your machine and the web server. Web browser sends a request via HTTP protocol to the server and web server sends response back to the web browser via HTTP protocol. HTTP is a short form of Hyper Text Transfer Protocol. HTTP is a textual protocol, meaning the requests and responses are sent in ASCII text between the client and the server.Here is a diagram illustrating request response over the internet:
A web server can host different file types as you usually keep on your local machine. Sometimes web server can also generate response dynamically if request page content information has been stored into the database on the web server.