Samiksha Hiwase I 6 Min Read I July 22, 2020

How to Make Fewer HTTP Requests to Speed Up Your Site

1. Quickeread

One of the most important aspects of a website that can make or break it is the page load time. 40 percent of your visitors can leave your site if it takes 3 seconds or more for your page to load.
Every time user visits a website, there is a whole lot of technical stuff going on behind the scenes. While words and images are loading on your screen, in the background your browser is requesting and receiving files from the server. The fewer HTTP requests your site sends to the server, the faster your site will load.
Let’s take a look at what are HTTP requests, how to reduce your website’s HTTP request, checking how many HTTP requests your website makes, and how does HTTP request impact the user experience.

2. What are HTTP requests?

Every time user visits on your site, their browser pings your web server and requests the files that include the content of the page. These files contain HTML, CSS, JavaScript files, images, icons, and other files.
The request is an HTTP request. HTTP stands for Hypertext Transfer Protocol and basically, the browser sends a request for a file and the server transfer that file to the browser.
When the server receives an HTTP request from a user’s browser, your server responds by sending the required files. The user’s browser then renders the page.
Why is it so important to keep track of HTTP requests?
Because every time someone visits your site, their browser needs to make a separate HTTP request for every single file. Almost the maximum website uses a lot of images, animations, and other dynamic content.
Reduce the number of elements of your site pages so, you can minimize the number of HTTP requests. This will help you to speed up loading times for your site.

3. How to reduce your website’s HTTP request

Let us now look into how to make fewer HTTP Requests of your site so as to increase the site speed.

Reduce the number of installed Shopify apps

A large number of apps on the Shopify store, automatically add some CSS/JavaScript files to your store. The problem here is that, if your app is not in use, the CSS/JavaScript files continue to run in the background and slow down your store’s performance.
Hence, the best idea to go through your store to check for apps that are no longer in use and delete them. So that your site will load faster. As long as the unutilized apps remain installed, they will continue to run their CSS/JavaScript files.

Perform lazy image loading

The method of Lazy Image Loading can prove as a powerful method when it comes to Shopify stores. This technique involves making use of a Javascript library to load images only when they should be visible to the site visitor. This improves page load time.
Lazy Image Loading is especially useful when the theme you use tall pages where a lot of the images will not be visible to the visitor until they scroll down. This means lesser HTTP Requests. Therefore, you will not need to load all the images initially.
Optimize the images and remove the file information that you think is not necessary. Also, make sure the size of the image files is not too large. Compress and perform optimization for images if necessary.

Perform code minification

An inefficiently coded HTML, Javascript, and CSS file on your page has several implications on your site’s performance. To resolve this problem efficiently, developers use a tool called a minifier that gets rid of the redundant code.

Use a fast and reliable hosting

Hosting service and infrastructure can make or break the performance of an e-commerce site. This is primarily true in high traffic and high transaction days.
Some factors to remember when deciding on hosting platform requirements include:
  • Memory as well as bandwidth limits that will determine if the platform will have the ability to scale per demand. Especially during seasonal promotions and flash sales.
  • The amount projected traffic as well as peak user load it can handle. This ensures that the platform will not crash when there is a sudden uptick in visitors.
  • Appropriate security, to ensure that your visitors and user’s data is secure at all times.

Download a responsive and fast theme

One of the main reasons for a slow store speed is the site theme. So, always check for the following aspects:.
  1. Select a responsive and fast theme.
  2. See if the theme has an updated version and have a look at the live preview.
  3. Once you select a theme, remember to ensure it is kept up to date.
  4. A theme that has been optimized for performance will have all styles in just one CSS file, all javascript in one javascript file. It is recommended that before zeroing down on a theme, run the theme through any tools like Google PageSpeed Insight, GTmetrix and analyze the results

4. Checking how many HTTP requests your website makes

Tools like GTmetrix, Google PagesSpeed Insight, and Pingdom can help you to track HTTP requests.GTmetrix is a free tool to check your web page performance. It analyzes your page performance and gives a score out of 100. It generates a report on the page load time, breaking down the total time duration based on different events/stages in the process of loading the page.
GTmetrix offers an easy way to check your YSlow score, which utilizes both PageSpeed and YSlow.
In the YSlow tab, you can then check the make a fewer HTTP request column.
It is always a good idea to reduce the number of HTTP requests as these can add up to significant load times. Sometimes this can increase the download time of your file, but it usually outweighs having additional requests.

5. How does HTTP request Impact User Experience?

The browser sends as many HTTP requests as the number of components on a page. The more elements a page has, the more HTTP Server Requests are sent, which takes more time to be processed. Consequently, it takes more time for the elements to load on the user’s screen.
The solution to this problem is to remove the number of elements on the page that will reduce the number of HTTP requests that the user’s browser sends to the server.
Therefore, fewer HTTP requests generated, and the site loads faster which gives a good impact on user experience.

For Further Details or Additional Information


If you want to know more about our Services