How to Reduce CPU Usage on HostGator (Bandwidth Limits)


Exceeding your bandwidth limits on HostGator?

Bandwidth limits happen when your hosting plan doesn’t have enough server resources to accommodate your plugins, images, theme, and other things that might be causing high CPU. You can use AWstats (built-in to your HostGator cPanel) and the Query Monitor plugin to find the source, but this tutorial outlines the most common solutions (I had CPU overages myself).

Just a heads up, HostGator is terrible. They restrict CPU usage and have slow server response times. Just look at the Facebook polls or read some conversations in the WordPress Hosting Facebook Group. They’re owned by EIG and have gone completely downhill. If you want to stop exceeding bandwidth limits, this guide will help, but I would switch to SiteGround or Cloudways. I use SiteGround (you can view my GTmetrix/Pingdom report with <1s load times).


1. Upgrade To PHP 7.2

Upgrading to PHP 7.1 or 7.2 can make your site significantly faster, while reducing CPU usage. This is especially true if you haven’t upgraded PHP versions for awhile (or have never done it).

Step 1: In your HostGator cPanel, select the PHP Selector.

Step 2: Select a newer PHP version (the higher, the faster).


Step 3: Check your website for errors. If you see errors, chances are you’re running plugins that aren’t compatible with the newer PHP version. In this case, run the PHP Compatibility Checker plugin to see which plugins are incompatible. You either need to delete these plugins (and replace them with plugins that are maintained better) or revert to an earlier PHP version.


Step 5: Enjoy your website which should be much faster.



2. Offload Resources To Cloudflare CDN

Offloading heavy files to Cloudflare’s 180+ data centers greatly reduces the load on your own server. Cloudflare’s CDN is free and quite simple to setup, just follow these instructions below.

Step 1: Sign up for Cloudflare (free plan).

Step 2: Run the scan and you will eventually come to a page with 2 nameservers.


Step 3: Login to your HostGator account > Domains > Gear Option > Change Nameservers.

Step 4: Replace HostGator’s nameservers with the ones Cloudflare’s provided you.

HostGator Nameservers


3. Control WordPress Heartbeat API

The WordPress Heartbeat API runs in the background of your admin panel automatically. It shows real-time plugin notifications, when other users are editing a post, and other resource-hungry tasks. This generates a request every 15-30 seconds, so it’s best to disable it to save on bandwidth. Install the Heartbeat Control plugin and set it to 60s, or better, disable it entirely.

Some cache plugins like WP Rocket have an option for heartbeat control.



4. Clean Your Database

A bloated database can slow down your website and also consume bandwidth. Install the WP-Optimize plugin and schedule it to run every 1-2 weeks, keeping your database nice and clean.

WP-Optimize Clean Database


5. Use A Great Cache Plugin

All 3 are super important:

  • If you’re using a cache plugin
  • Which cache plugin you’re using
  • Whether the settings are configured optimally

If you can afford $49/year, WP Rocket was rated the #1 cache plugin in multiple Facebook polls. That’s because it comes with many features most cache plugins don’t (see below). Otherwise, you would need to install about 6 extra plugins to get these features, when WP Rocket has them all built-in, reducing the number of plugins on your site. If you use another cache plugin, you’ll want to research which features that specific cache plugin comes with, then install these plugins if it doesn’t support them.

WP Rocket has more features than other cache plugins:


If you can’t afford WP Rocket, I recommend either Swift Performance or WP Fastest Cache.


6. Configure Optimal Cache Plugin Settings

I wrote tutorials for the most popular cache plugins. It is very important you configure these optimally… even 1 simple setting (eg. object cache) can greatly affect load times.


7. Eliminate High CPU Plugins

Too many plugins (or 1 single high CPU plugin) can skyrocket bandwidth usage. Common high CPU plugins include social sharing, statistic, backup, live chat, page builders, and related post plugins. You should either delete them, replace them with lightweight plugins (you may need to do research), or you will need a hosting plan with enough server resources to accommodate them. Thank you Ivica from the WordPress Speed Up Facebook Group for starting this list.

  1. AddThis
  2. AdSense Click Fraud Monitoring
  3. Backup Buddy (use UpdraftPlus)
  4. Beaver Builder
  5. Better WordPress Google XML Sitemaps
  6. Broken Link checker (use Dr. Link Check)
  7. Constant Contact for WordPress
  8. Contact Form 7 (load JS + stylesheet only when necessary)
  9. Contextual Related Posts
  10. Digi Auto Links
  11. Disqus Comment System (use Disqus Conditional Load)
  12. Divi Builder
  13. Essential Grid
  14. Fuzzy SEO Booster
  15. Google XML Sitemaps
  16. Jetpack
  17. NextGEN Gallery
  18. NewStatPress
  19. Really Simple Share
  20. Reveal IDs
  21. Revolution Slider
  22. ShareThis
  23. S2 member
  24. SEO Auto Links & Related Posts
  25. Similar Posts
  26. Slimstat Analytics
  27. SumoMe
  28. Talk.To
  29. Ultimate Social Media & Share
  30. VaultPress
  31. Wordfence (disable live traffic reports)
  32. WordPress Facebook
  33. WordPress Related Posts
  34. WordPress Popular Posts
  35. WP Bakey (formerly Visual Composer)
  36. WP Statistics
  37. WP Power Stats
  38. WP-PostViews
  39. WPML (if you use too many extensions)
  40. wpCloaker
  41. WPML
  42. Yet Another Related Post Plugin
  43. Yuzo Related Posts

You can also use the GTmetrix Waterfall tab (or Query Monitor) to find your slowest plugins:


If you plan on using resource-hungry plugins, you will inevitably need to upgrade your HostGator plan (their business plan is better, their VPS is even better but if you’re spending that kind of money, you’ll be better off with SiteGround, Cloudways, Kinsta, or WP Engine).


8. Eliminate External Resources

External resources are almost inevitable. Embedding a YouTube video, a tweet, using a social plugin that connects to Facebook, Google Fonts, running AdSense… these will generate extra requests and will likely appear in your GTmetrix / Pingdom reports. Here are some quick tips:

Prefetch DNS Requests
In cases where you must use external resources, you can prefetch them. This helps browsers anticipate them and loads them faster. Luke created a nice list of common domains to prefetch including Google Maps, Fonts, Analytics, YouTube (when embedding videos), Disqus and more.


WP Rocket has an option for prefetching:


Otherwise you can add it to your header:

<link rel=”dns-prefetch” href=”//”>
<link rel=”dns-prefetch” href=”//”>
<link rel=”dns-prefetch” href=”//”>


9. Serve Scaled Images

If you see serve scaled image errors in GTmetrix, it means you need to resize large images. GTmetrix tells you which images need to be resized and their correct dimensions, but it only shows unoptimized images for the single page you test. If you have common image dimensions (sliders, widgets, carousel, fullwidth blog images) you can create a cheat sheet with all their dimensions. Then crop/resize images before uploading them. This can save you time, and CPU.

Serve Scaled Images


10. Losslessly Compress Images

This means you need to lossless compress them (ShortPixel is great). Set the compression level, then optimize a couple images in your media library to make sure you’re happy with the quality. If yes, you can bulk optimize images, and automatically compress images upon upload.



11. Block Spam Bots

These are way more common than you think. was hitting my site every 3 seconds and draining CPU on literally nothing. If you haven’t checked to see which bots are hitting your site, I would 100% do this.

Install Wordfence and use their live traffic report to see all bots hitting your site in real-time.


Write down all hostnames that look suspicious and hit your site frequently. Google them, and see if other people are reporting them as spam. If yes, go to Wordfence’s Blocking settings (you can also use Cloudflare firewall rules) and block the spam bots here. Be sure to user an asterisk to block all variations of that bot. Check your blocking log and watch the bots get blocked. If your site was getting hit frequently by spam bots, this can save a LOT of bandwidth.


Wordfence also has rating limiting settings. This limits/blocks crawlers (and humans) from making excessive requests, blocks fake Google crawlers, and improves security on 404 pages. The settings below are the same ones recommended by Wordfence on their rate limiting page.


Another alternative, is to simply install the Blackhole For Bad Bots plugin.

Blackhole for Bad Bots


Hotlink protection prevents people from copying your images and pasting them on their website, which consumes bandwidth since you are still hosting those images. This usually only happens if your website has high quality images (eg. photography). Follow these instructions:

  1. Login to cPanel and click HotLink Protection.
  2. Make sure the domain name you wish to protect is in the box called “URLs to allow access”.
  3. In the box called “Block direct access for these extensions”, provide the extensions for which you would like to block.
  4. We suggest you check the box for “Allow direct requests”.
  5. Skip the “Redirect request to this URL” box and hit Submit.

Cloudflare also has an option for hotlink protection in the scrape shield settings:

Cloudflare Hotlink Protection


13. Check AWstats To Find Source Of High CPU

AWstats is built-in to the statistics section of your HostGator cPanel and can help you identify the source of high CPU. It tells you exactly how much bandwidth is consumed by bots, images, and other elements. Remember, you can block spam bots with Wordfence or the Blackhole For Bad Bots plugin, and you can optimize your images using tools like GTmetrix and ShortPixel.



14. Check Server Response Times

Slow server response times are never good for CPU, load times, or anything. Run your site Google PageSpeed Insights and check if improve server response time appears in your report.

CPU and server response times go hand-in-hand. If you went through my tutorial and you still have high CPU usage on HostGator, you probably know what the problem is – it’s HostGator.



15. Get Better Hosting

HostGator sucks.

They were rated very poorly in Facebook polls and people constantly complain about their slow server response times, bandwidth limits, and of course their bad support and uptimes.

I use SiteGround and have 200ms response times with 100% GTmetrix scores and .4s Pingdom load times. Do a hosting check, run your own tests, or click through my fast loading pages. They were rated the #1 host in 26 Facebook polls and are worlds better than EIG (Bluehost, HostGator), GoDaddy, and other hosts who pack too many people on the same server. There have been plenty of people who migrated and posted results on Facebook and Twitter. Tweet after tweet, post after post, poll after poll after poll, faster hosting will fix slow response times. They’re recommended by WordPress, do free migrations, and I use their semi-dedicated plan.

2019 Hosting PollView Poll

People usually migrate because their speed technology can improve server response times by multiple seconds. Here are a few people who migrated to SiteGround and posted their results.

I’m on their semi-dedicated GoGeek plan with a .5s load time in GTmetrix…



SiteGround has 3 plans which are 77% off for Labor Day:

SiteGround Hosting Plans

Higher plans include more server resources (#1 factor in the WordPress optimization guide). Here’s the full comparison chart, but GrowBig gives you about 2x more server resources than StartUp, and GoGeek is semi-dedicated hosting which gives you even more. GrowBig and up comes with a free migration, staging, advanced caching, and ability to host multiple websites. GoGeek comes with priority support. Their cloud hosting is quite the price jump at $80/month.

You can see this on the features page…


I use SiteGround because:

  1. My GTmetrix + Pingdom reports speak for themselves
  2. My pages load instantly (click through them if you want)
  3. Fast speed technology (PHP 7.3, NGINX, SG Optimizer, Cloudflare)
  4. Recommended by Yoast, WordPress, Ivica from WordPress Speed Up
  5. Free Let’s Encrypt SSL, easy to use cPanel, and features for eCommerce
  6. WordPress support is unbeatable even without GoGeek’s priority support
  7. GrowBig comes with staging, more storage, and more server resources (scroll down to “we allocate the resources you need” and hover over the server tab)
  8. GoGeek comes with even more server resources, storage, priority support
  9. Free migrations, migrator plugin, and a 30-day money back guarantee
  10. Plenty of praise on Reddit, Facebook conversations, Twitter, TrustPilot
  11. Tons of praise on Facebook: #1, #2, #3, #4, #5, #6, #7, #8, #9, #10, #11
  12. Many people already migrated and posted results on Twitter: #1, #2, #3, #4, #5, #6, #7, #8, #9, #10, #11, #12, #13, #14, #15, #16, #17, #18, #19, #20, #21, #22, #23, #24, #25, #26, #27, #28, #29, #30, #31, #32, #33, #34, #35, #36, #37

Affiliate Disclaimer – if you sign up for SiteGround using my affiliate link I will donate a good chunk at no cost to you. Each year I donate $3,000 to GoFundMe campaigns (2018 was to feed the hungry in Denver, 2017 was to Red Cross at Hurricane Harvey). Your support helps and I genuinely appreciate it. Either way, I would avoid HostGator – join some Facebook groups and see the conversations, polls, tweets, and those who migrated from HostGator to SiteGround. I refuse to send people to HostGator or EIG. Do your research, see who Yoast is using, and results of people who already migrated.

Read up for yourself:

HostGator Server Response Time

HostGator Feedback




Hope this helped.


span,.wp-review-50635.wp-review-percentage-type .review-list li>span{display:inline-block;position:absolute;z-index:1;top:32px;left:45px;color:#ededed;font-size:14px;line-height:1;text-shadow:0 1px 1px rgba(0,0,0,.3);-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.wp-review-50635.wp-review-point-type .wpr-user-features-rating .review-list li>span,.wp-review-50635.wp-review-percentage-type .wpr-user-features-rating .review-list li>span{color:inherit;text-shadow:none}.wp-review-50635.wp-review-point-type .wpr-user-features-rating .review-list li .wp-review-input-set+span,.wp-review-50635.wp-review-percentage-type .wpr-user-features-rating .review-list li .wp-review-input-set+span,.wp-review-50635.wp-review-point-type .wpr-user-features-rating .review-list li .wp-review-user-rating:hover+span,.wp-review-50635.wp-review-percentage-type .wpr-user-features-rating .review-list li .wp-review-user-rating:hover+span{color:#fff}.wp-review-50635 .review-list li:nth-child(even){background:#fff}.wp-review-50635 .review-links{padding:30px 30px 20px 30px} .review-result-wrapper i{font-size:18px} .review-pros-cons{clear:both;padding:0;border-top:1px solid #fff} .review-pros-cons .review-pros, .review-pros-cons .review-cons{width:100%;flex:none;padding:0} .review-pros-cons .review-pros{background:#2c3fd3;padding:30px 30px 10px 30px;color:#fff;box-sizing:border-box} .review-pros-cons .review-cons{background:#5e1d9a;padding:30px 30px 10px 30px;color:#fff;box-sizing:border-box} .mb-5{text-transform:uppercase} .mb-5+p{line-height:26px}.wp-review-50635 .user-review-area{padding:15px 30px;border-top:1px solid}.wp-review-50635 .wp-review-user-rating .review-result-wrapper .review-result{letter-spacing:-2.35px} .review-title{letter-spacing:1px;font-weight:700;padding:15px 30px;background:transparent} .review-total-wrapper{width:40%;margin:0;padding:35px 0;color:#fff;background:#ededed;border-left:1px solid;text-align:center;float:right;clear:none;border-top:1px solid} .review-list{clear:none;width:60%;float:left;border-top:1px solid} .wpr-user-features-rating, .wpr-user-features-rating .review-list{width:100%;clear:both;border-top:1px solid #fff} .review-total-wrapper{padding:20px 0} .review-total-wrapper{margin:auto 0;padding-top:10px;width:auto;height:100%;clear:both} .user-review-area{padding:12px 30px} .review-list{width:100%} .review-result-wrapper{border-radius:25px} .review-percentage .review-result-wrapper, .review-percentage .review-result, .review-point .review-result-wrapper, .review-point .review-result{height:26px;margin-bottom:0;background:#fff;border-radius:25px} li .review-point .review-result{background:#5e1d9a} li:nth-of-type(2n) .review-point .review-result{background:#2c3fd3}.wp-review-50635 .review-total-wrapper,.wp-review-50635 .review-total-wrapper{width:70%;display:inline-block;margin:20px auto 0 auto} .review-total-wrapper .review-total-box{float:left;text-align:center;padding:0;color:#424242;line-height:1.5} .review-total-wrapper .review-total-box h5{margin-top:10px;color:inherit} .review-total-wrapper .review-total-box, .review-total-wrapper .review-total-box{width:100%}{color:#fff;margin-top:10px} .user-review-title{padding:15px 30px 10px;margin:0;color:inherit;background:#fff;border-top:1px solid;border-bottom:1px solid} .user-total-wrapper .user-review-title{display:inline-block;color:#424242;text-transform:uppercase;letter-spacing:1px;padding:0;border:0;background:transparent;margin-top:3px} .user-total-wrapper h5.user-review-title{margin-top:12px} .user-total-wrapper span.user-review-title{margin-top:8px} .reviewed-item{padding:30px} .review-total-wrapper>.review-total-box{display:block} .review-total-wrapper>.review-total-box>div{display:none} .user-review-area .review-percentage, .user-review-area .review-point{width:20%;float:right;margin-bottom:5px}.wp-review-50635 .review-embed-code{padding:10px 30px},.wp-review-50635 .review-title,.wp-review-50635 .review-list li,.wp-review-50635 .review-list li:last-child, .review-list,.wp-review-50635 .user-review-area, .review-total-wrapper,.wp-review-50635 .reviewed-item,.wp-review-50635 .review-links,.wp-review-50635 .wpr-user-features-rating, .user-review-title{border-color:#fff}.wp-review-50635 .wpr-rating-accept-btn{background:#5e1d9a;margin:10px 30px;width:-moz-calc(100% – 60px);width:-webkit-calc(100% – 60px);width:-o-calc(100% – 60px);width:calc(100% – 60px);border-radius:50px}@media screen and (max-width:480px){ .review-title, .reviewed-item, .review-list li, .review-desc, .user-review-area, .review-embed-code{padding:15px}.wp-review-50635.wp-review-circle-type .review-list li{padding:15px 15px 0 15px} .review-pros-cons>div>div{padding:15px;padding-top:0} .ui-tabs-nav{padding:0 15px} .review-links{padding:15px 15px 5px} .review-list, .review-total-wrapper{width:100%} .review-total-wrapper{padding:10px 0} .review-total-wrapper .review-total-box h5{margin-top:0} .review-total-wrapper .review-total-box div{line-height:1}}]]>

Keep reading the article at Tom Dupuis. The article was originally written by Tom Dupuis on 2019-05-31 11:52:46.

The article was hand-picked and curated for you by the Editorial Team of WP Archives.

Disclosure: Some of the links in this post are "affiliate links." This means if you click on the link and purchase the product, We may receive an affiliate commission.

Leave a Comment

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

Show Your ❤️ Love! Like Us
Scroll to Top