How to Reduce HTTP/S Requests to Speed Up Your WordPress Site

We all have a concern about the page loading time of our sites. Side by side we want to make our site lucrative by adding more images, videos, animations, etc. All of the new assets creates HTTP/S request from our Visitor’s Browser to our server. And these requests also a major reason to slow down our site speed. It’ll hamper the user experience of the valued visitor. In this article, I tried to cover up possible ways to reduce HTTPS request which will definitely help us to speed up our WordPress Site.

Maybe You Have A Question; Does HTTP Matter to the User Experience?

Ok fine. I’ll try to clear up your confusion. When a visitor pays a visit to your site his/her browser sends lots request HTTPS request to your server. And your server then sends the data as per requirements. If your server gets too many requests then it has to reply to the request. In the meanwhile, your page loading time increases. For that reason, 40% of your visitor left your site and as a reward, they give you a high amount of bounce rate. Finally, you are affected in the global ranking. Here is an infographic content by Neil Patel on page loading time effects.

loading-time gtarafdar
How Loading Time Affects Your Bottom Line

How to Track HTTPS Server Requests and Related Issues

Don’t worry. You don’t have to spend a penny to track down the HTTPS server requests. There are so many free resources that will help you to trace the request. Even though you can easily find out from your Chrome Browser.

Just Navigate to ⇉  Chrome Menu ⇉ More Tools ⇉ Developers Tools ⇉ Tap to Network Tab ⇉ (For more specific results just hover your mouse to any link)

HTTPS-finding-from-chrome gtarafdar
Tracking HTTPS Requests form Chrome Browser

This is not the one & only tool from Google. You can try the PageSpeed Insights tool for checking the requests.

I know you are familiar with those tools. Here I listed a few more tools to help you in saving your time on searching purposes.

Among those three tools, I like Pingdom very much because of its amazing interface.

How to Reduce the Number of HTTPS Server Requests for Your WordPress Site

I know you are waiting for that part. Now I will share some proven methods which gonna help you to reduce the number of HTTPS Server requests. Stay connected.

#1. Disable Your Default Gravatars

Maybe I give a shock. Why I’m telling you to disable the default WordPress Gravatars! Here is the reason. If you are using the native WordPress commenting system by default it creates a separate HTTP request for each gravatar. When one of your blogs get so many comments then your site will get too much gravatar requests like that-

gravatar-request gtarafdar
Gravatars request

You can easily remove your Native Gravatar with your local Gravatar easily. I know it’s not the right thing. But when it comes to your site’s speed then you will definitely have to think of it.

By the  WP User Avatar Free WordPress Plugin, you can easily disable that and set your local gravatar for your users.

#2. Enable Lazy Load for Disqus

There is no doubt about the best features of the Disqus commenting plugin. But it creates 10+ HTTPS requests for your server. If you are using Disqus as your commenting purpose then I suggest you try the Disqus Conditional Load. This amazing plugin is created by Joel James. It’s SEO friendly and moreover, this plugin doesn’t require jQuery. They use pure JavaScript.

#3. Disable Emoji from Your Site

Sorry if you are a fan of emojis like me then please skip this section. If not then continue. From the WordPress Version, 4.2  WordPress officially provides emoji supports. There is a file named wp-emoji-release.min.js?ver=4.3.1 appears in your site’s header section and it creates a bunch of HTTPS requests to your server. You can disable the emoji by following these two methods.

  • By Activating “Disable Emojis” by Ryan Hellyer. This is an easy peasy solution for you if you are non-coder. Check this out from here-
  • If you don’t want the activate another plugin then simply take the code from Ryan’s plugin and drop it into the bottom of your functions.php file.
/** * Disable the emoji's */ function disable_emojis() { remove_action( 'wp_head', 'print_emoji_detection_script', 7 ); remove_action( 'admin_print_scripts', 'print_emoji_detection_script' ); remove_action( 'wp_print_styles', 'print_emoji_styles' ); remove_action( 'admin_print_styles', 'print_emoji_styles' ); remove_filter( 'the_content_feed', 'wp_staticize_emoji' ); remove_filter( 'comment_text_rss', 'wp_staticize_emoji' ); remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email' ); add_filter( 'tiny_mce_plugins', 'disable_emojis_tinymce' ); } add_action( 'init', 'disable_emojis' ); /** * Filter function used to remove the tinymce emoji plugin. * * @param array $plugins * @return array Difference betwen the two arrays */ function disable_emojis_tinymce( $plugins ) { if ( is_array( $plugins ) ) { return array_diff( $plugins, array( 'wpemoji' ) ); } else { return array(); } }

#4. Disable Embeds

Since WordPress Version 4.4, it came with this wp-embed.min.js script. It mainly helps to embed any posts, tweets, videos, etc. Maybe you are a fan of that feature. But the problem is, this file always load in you each page whether you are using it or not. It requests HTTPS to your server also. Now you can disable that script in two ways.

  • Install the free WordPress plugin “Disable Embeds” by Pascal Birchler.
  • This plugin does the following:
    • Prevents others from embedding your site.
    • Prevents you from embedding other non-whitelisted sites.
    • Disables all JavaScript related to the feature.
    • It’s a very lightweight plugin.
  • If you don’t want to install a plugin then you can drop the following into the bottom of your functions.php file to also disable embeds.
// Remove WP embed script 
function speed_stop_loading_wp_embed() { 
if (!is_admin()) { wp_deregister_script('wp-embed'); } } add_action('init', 'speed_stop_loading_wp_embed');

#5. Remove Query String

Every string ended up with version numbers and these are called query strings and help determine the version of the script. The problem with query strings like these is that it isn’t very efficient for caching purposes and sometimes prevents caching those assets altogether. You can easily remove query strings by following these two methods.

  1. By activating a free plugin Query Strings Remover you can easily remove your sites query strings. It’s also a very lightweight plugin.
    PS: This plugin is not tasted with WordPress 5.1 & has no updates for 1 year. So please it’s your call.  
  2. You can easily remove the query strings by adding the below codes into your functions.php file.
function _remove_script_version( $src ) { $parts = explode( '?ver', $src ); return $parts[0]; } add_filter( 'script_loader_src', '_remove_script_version', 15, 1 ); add_filter( 'style_loader_src', '_remove_script_version', 15 );

#6. Disable Your Scripts on Your Page Level Basis

There is a plugin called Gonzalez which actually lets you disable unnecessary scripts from loading on a page-level and site-wide basis. It isn’t free, but well for the money if you are trying to squeeze out a little more speed. For example, Contact Form 7 is a great form plugin for WordPress, but by default, it loads its script on every single page. With this plugin, you can easily disable it and only load it on your contact page.

page-level-scripts gtarafdar
Disable Scripts on a Page-level Basis

#7. Deleting Unwanted Images from Your Database

Most of the cases we forget to remove the extra images from our sites. As we know every file creates a request for HTTPS to our server. So we need to remove the unwanted image files. Please please be aware of not deleting the important images. The best practice is to taking time while uploading images in your sites.

deleting-images gtarafdar
Deleting Unwanted Images

#8. Create a CSS Image Sprite

With the help of CSS, you can create CSS Image Sprite. It’s basically a combination of a number of images into a single one. It helps you to create a single HTTPS request for multiple images. You can create your own CSS Sprite by following the guideline of W3School. Or you can take help from these CSS Image Sprites making sites.

CSS-Image-Sprite gtarafdar
CSS Image Sprite Example – w3school

#9. Ignore Irrelevant Assets

You can easily ignore irrelevant assets by activating the Free Plugin WP Asset Cleanup plugin. Basically, it scans your page and detects all the assets that are loaded. All you have to do when editing a page/post is just to select the CSS/JS files that are not necessary to load, this way reducing the bloat. It then keeps that asset from being loaded and detected on that page; thus, decreasing the number of server requests that have to go out to browsers.

#10. Combine CSS and JavaScript Files

WordPress site is bound to have numerous CSS and JavaScript Files. It’s the best practice to Combine CSS and JavaScript Files into a common singular file. Rather than leaving them to create the single HTTPS requests of each CSS and JavaScript Files for your server.

Just keep in mind that your merged CSS file should reside within the header of your website. Your JavaScript file then needs to go in the footer.

You can merges/concatenates Cascading Style Sheets & Javascript files into groups by this free plugin Merge + Minify + Refresh.

## Bonus Tips

If you don’t want to go through these steps then you can try some premium caching plugins or site optimizing tools. Then you can be relaxed by handed over your hassle to them. You can try WP-Rocket, Perfmatters. These tools will help you a lot in optimizing your site along with your site speed.

wordpress-performance-plugin-01-gtarafdar
WordPress performance plugin – Perfmatters

Ending Thoughts

Finally, I came to an end. These are all about my little knowledge regarding the techniques of Reducing HTTP/S Requests to Speed Up A WordPress Site. If you want to know a little bit more about site optimization techniques then this article is for you- Tips for Optimizing Your WordPress Site to Speed Up Extremely. Moreover, if you have some other techniques to reduce HTTPS requests then please share it in the comment section. It’ll help us a lot.

3 replies on “How to Reduce HTTP/S Requests to Speed Up Your WordPress Site”

[…] Rocket is a premium caching and performance plugin that makes a wide variety of tweaks to speed up your WordPress site. This cache plugin creates a cache of the static file of your blog posts, and when a user accesses […]

It was a very interesting blog which was about minimizing the http wordpress website. There are several ways to minimize HTTP requests on a WordPress site, which can improve your site’s loading speed and overall performance. Here are some effective methods:
1.Minimize plugins.
2.Combine CSS and JS files.
3.Use a caching plugin.
4.Optimize images.
5.Use a Content Delivery Network (CDN)
These are some points which I thought to include in your article.

Leave a Reply

Your email address will not be published. Required fields are marked *

0 Shares
Share via
Copy link
Powered by Social Snap