Website Design Orlando

Responsive-Mobile design by Irina Blumenfeld

  • About
  • Services
    • Website Design
    • Local SEO
    • Digital Marketing
    • Website Care
  • Projects
  • Testimonials
  • Articles
    • Speaking
    • Tutorials
    • Resources
  • Support
  • Contact
  • Twitter
Home / Tutorials / How to remove query strings from static resources

How to remove query strings from static resources

Updated: February 5, 2019 //

If you test your website speed with tools, such as GTMetrix.com, or on Pingdom Tools, you’ll see a suggestion: Remove Query strings from static resources.

How to remove query strings from static resources
Resources, containing query strings cannot be cached. You’ll get an improved speed score if you remove those query strings.

Files that display a query string are either CSS or JavaScript.

This is because the default behavior for the WordPress wp_enqueue_script function is to append a string specifying the script version number.

When developers add a version number, it is concatenated to the end of the path as a query string. If no version is specified or set to false, then WordPress automatically adds a version number equal to the current version of WordPress you are running.

If you add the following code to your theme’s functions.php file, you will remove the query string version numbers from all of your scripts at once, which in turn results in an improved score in Google PageSpeed.

How to remove query strings from static resources:

5/5 (5 Reviews)

Recent Posts

list-of-resources-to-speed-up-your-website

List of resources to speed up your website

This list includes: Online tools to test website speed Articles to interpret results Performance statistics Books on how to improve website performance CDN providers Online[Read More…]

speed up your website

WordCamp Orlando 2016

I was happy to speak at WordCamp Orlando. This event was held on November 12-13, 2016 at the UCF Rosen College of Hospitality Management. We[Read More…]

rate-us

How to add star rating in WordPress

★ ★ ★ ★ ★ Recently I had to include star rating on my client’s website. The goal was to offer easier and faster way[Read More…]

About Irina Blumenfeld

Web Consultant, empowering business owners through WordPress. Passionate about Web Performance.
Follow on Twitter

Comments

  1. Michael says

    June 25, 2016 at 10:17 am

    Hello. I have been searching for days to learn how to remove query strings from a non-WP website. I have had no luck. Any ideas? Would I need to edit the htaccess file?

    • Irina Blumenfeld says

      June 26, 2016 at 8:10 pm

      It depends on CMS that you are using, or is it a static site? Here’s a tutorial to remove it in Drupal or in Joomla: https://www.keycdn.com/support/remove-query-strings-from-static-resources.
      You might want to post a specific question on http://stackoverflow.com

  2. Kriston says

    October 10, 2017 at 6:41 pm

    Irina what about: https://wordpress.org/plugins/remove-query-strings-littlebizzy/

    easy install one click… no settings… cheers

    • Irina Blumenfeld says

      October 11, 2017 at 11:23 am

      You can use a plugin too. But it adds another plugin to your website that you have to maintain and update.

Categories

  • Resources (6)
  • Speaking (14)
  • Tutorials (17)

More Articles

  • WordCamp Orlando 2019
  • Stand Out In Search Results
  • How To Make Your Site Stand Out In Search Results
  • Speeding Up WordPress
  • Why we use SiteGround for website hosting
  • WordCamp Jacksonville 2018
  • WordPress Orlando Gutenberg Meetup
  • WordCamp Miami 2018
  • Steps to do before launching a WordPress website
  • 10 Steps To Do Before Launching Your WordPress Website
  • Why is my WiFi so Slow? Best ways to Fix Slow WiFi at home
  • WordCamp Orlando 2017
  • How to hide author username in Beaver Builder Posts Module
  • How to fix slow loading images
  • Best Practices For Faster Websites
  • Plugins
  • WordCamp Orlando 2016
  • How to add star rating in WordPress
  • Make WordPress website faster in 3 steps
  • Migrate WordPress to HTTPS
  • Why you should migrate to HTTPS
  • WordCamp Jacksonville 2016
  • How to disable Emojis in WordPress
  • WordCamp Miami 2016
  • How to remove query strings from static resources
  • How to enable Free SSL, HTTP/2 protocol and CDN
  • Improve Your Website Performance
  • List of resources to speed up your website
  • 10 ways to speed up your website
  • Benefits of HTTP/2 Protocol
  • How to add custom post types to a Widget
  • Add previous/next links on single page of custom post type in Genesis
  • How to add text “Menu” next to Hamburger Icon
  • About
  • Services
  • Projects
  • Testimonials
  • Articles
  • Support
  • Contact
  • Twitter

Copyright © 2021 · Netmagik.com · All Rights Reserved · Privacy Policy · Disclosure · Sitemap
WordPress hosting by SiteGround
Tools We Recommend

Twitter Facebook Linked In Github Codepen