“Why is this page taking so long to load?!” This is a common theme with Internet users — why is it that web pages take so long to load on one’s browser?
The reason for this is (unsurprisingly) complex and multifaceted. The Internet is richer in content and media than it was in yesteryear — there is more interactivity, larger bandwidth options by Internet Service Providers (ISPs), and more web traffic. Web pages are filled with so much material, and the technologies driving these pages are becoming so much more complex. “OK, I get it! It’s technical. Speak English now.”
When someone jumps on the web (via a web browser such as Internet Explorer), a couple of things happen while accessing a website (e.g., http://www.google.com). The web browser says, “OK, you want to go to google.com. Let me check with the Internet to find the exact address for that link.” This process of identifying where to go — finding an Internet Protocol (IP) for google.com— could take a couple seconds to locate. Fortunately, countless computers request the IP for google.com; Internet servers cache popular sites like this for future requests to speed up the process.
“OK, so we found the site, now what?” Your computer will then ask Google’s computer(s) for a list of the content on the requested page (http://www.google.com/ has a couple of images and a couple of web files). One way this is optimized is by an acknowledgement between Google and your computer to identify which files have already been saved/cached on your computer (by comparing dates and file sizes). This comparison prevents re-downloading those files, thus reducing the total data to download from the site. For files that haven’t been previously saved, your machine and Google will determine if it is OK to save them for quicker future access.
Have I still got your attention? We went over the following: caching the IP address for a website and caching a web page’s assets (images and files). What else is there to be optimized? How else can we speed up the loading of web pages? I’m sure you are asking yourself all of these questions in that exact order right now … right? Well, I’m going to start dropping some golden information on your collective consciousness now.
So, images are drawn onto the screen using format-specific algorithms that interpret image data. For example, bitmap files are processed and drawn differently than JPEG or GIF files. Some images are compressed more than others — this means they are smaller in file size (and likely image quality). One way to reduce image sizes (thus optimizing your web page’s load time) is to remove unnecessary color information (i.e., making the image’s color scheme “web safe.”) This reduction in information reduces file size tremendously, but can also noticeably alter quality; thus, it must be adjusted carefully.
There is also a way to reduce file sizes between computer servers and your computer by different forms of compression. The most popular compression is “gzip” or “gzipping.” When a file is transmitted over the Internet, it can be compressed via the gzip format, making the file size smaller and thus faster to receive on the client end. Gzip is similar to the zip” format, but for the Internet, and using it with the minifying process can optimize the transmission of large files by large percentages!
So, what have we learned today? The Internet is a place of wonderment and baffling processes. It is fraught with confusing terminology and scary server rooms. It also offers web designers and developers different tools to speed up the time to load web pages. This can be done by reducing the number of colors used in GIF images. Script files can also be “minified” to reduce file sizes. Developers can also send files to clients using special compression techniques like gzip. By reducing the number of files, images and file sizes, and by using complex processes, developers can optimize their webpages and provide clients faster load times.