Title: WP Remove Query Strings From Static Resources
Author: Rinku Y
Published: <strong>Jiyè 3, 2017</strong>
Last modified: Jiyè 11, 2026

---

Search plugins

![](https://ps.w.org/wp-remove-query-strings-from-static-resources/assets/banner-
772x250.png?rev=1689587)

![](https://ps.w.org/wp-remove-query-strings-from-static-resources/assets/icon-256x256.
png?rev=1689587)

# WP Remove Query Strings From Static Resources

 By [Rinku Y](https://profiles.wordpress.org/rinkuyadav999/)

[Download](https://downloads.wordpress.org/plugin/wp-remove-query-strings-from-static-resources.2.4.zip)

 * [Details](https://hat.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/#description)
 * [Reviews](https://hat.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/#reviews)
 *  [Installation](https://hat.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/#installation)
 * [Development](https://hat.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/#developers)

 [Support](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/)

## Description

**WP Remove Query Strings From Static Resources** is a lightweight, zero-configuration
WordPress plugin that automatically removes query strings (like `?ver=6.6`) from
your local CSS and JavaScript file URLs. It intelligently ignores external resources(
such as third-party APIs like Google Maps) to prevent breaking their functionality,
and features strict extension checking to protect dynamic scripts.

By default, WordPress appends version parameters to static resource URLs — for example:

    ```
    https://example.com/style.css?ver=6.6
    ```

While this helps with cache-busting during development, it prevents proxy servers
and CDN networks from properly caching these files, which hurts your website’s performance
score.

This plugin strips those query strings, turning URLs like:

    ```
    https://example.com/style.css?ver=6.6
    ```

into clean, cacheable URLs like:

    ```
    https://example.com/style.css
    ```

#### Why Does This Matter?

Speed is a critical ranking factor for search engines. Tools like **Google PageSpeed
Insights**, **GTmetrix**, **Pingdom**, and **YSlow** flag query strings on static
resources as a performance issue. Removing them can:

 * ✅ Improve your website performance score
 * ✅ Enable better proxy and CDN caching
 * ✅ Reduce page load time for returning visitors
 * ✅ Contribute to better SEO rankings
 * ✅ Improve overall user experience

#### How It Works

Once activated, the plugin hooks into WordPress’s built-in `script_loader_src` and`
style_loader_src` filters and silently removes all query string parameters from 
your local CSS and JS URLs — on the frontend only. The WordPress admin dashboard
is never affected.

No setup required. No settings page. Just install, activate, and you’re done.

#### Features

 * Removes all query string parameters from local CSS and JS URLs (not just `?ver`)
 * Safely ignores external resources to avoid breaking third-party scripts and APIs
 * Strictly targets files ending in `.css` and `.js` to protect dynamic PHP scripts
   enqueued as styles/scripts
 * Works automatically on activation — no configuration needed
 * Frontend-only — does not affect the WordPress admin area
 * Extremely lightweight — zero impact on page generation time
 * Compatible with all themes and plugins

[Learn more about Query Strings on Wikipedia](https://en.wikipedia.org/wiki/Query_string)

#### Upgrade to Pro

Get even faster load times and more advanced features with **Pro**!

 * **Advanced Caching & Compression**: Browser Caching with Customizable Cache Durations,
   GZIP Compression, Cache-Control Headers, Keep-Alive, and ETag Removal.
 * **Code Minification**: Minify CSS, JS, and HTML, plus Delay JavaScript for a 
   massive PageSpeed boost.
 * **Media & Font Optimization**: Lazy Load Images & iFrames, and Google Fonts Optimization.
 * **Database & Site Health**: Database Cleanup, DNS Prefetch, Preload Links, Heartbeat
   Control, and XML-RPC Disable.
 * **WooCommerce Ready**: Built-in WooCommerce Optimization.
 * **Settings Admin Page**: Easy-to-use interface to manage all features.
 * **Premium Support & Updates**: Get fast, dedicated assistance and regular new
   features.

[Upgrade to Pro!](https://lbcache.com)

## Screenshots

[⌊Code View⌉⌊Code View⌉[

Code View

## Installation

There are three ways to install this plugin:

#### Option 1: Install via WordPress Dashboard (Recommended)

 1. Go to **Dashboard > Plugins > Add New**.
 2. Search for **WP Remove Query Strings From Static Resources**.
 3. Click **Install Now**, then click **Activate**.
 4. That’s it — the plugin works immediately, no configuration needed.

#### Option 2: Upload via WordPress Dashboard

 1. Download the plugin ZIP file from the [WordPress Plugin Repository](https://wordpress.org/plugins/wp-remove-query-strings-from-static-resources/).
 2. Go to **Dashboard > Plugins > Add New > Upload Plugin**.
 3. Choose the downloaded ZIP file and click **Install Now**.
 4. Activate the plugin from the Plugins page.

#### Option 3: Upload via FTP

 1. Download and extract the plugin ZIP file.
 2. Upload the `wp-remove-query-strings-from-static-resources` folder to `/wp-content/
    plugins/` on your server.
 3. Go to **Dashboard > Plugins**, find the plugin, and click **Activate**.

## FAQ

### Does this plugin have a settings page?

No. This plugin works automatically as soon as you activate it. There are no settings
to configure.

### Will it affect my WordPress admin dashboard?

No. The plugin only runs on the frontend of your website. The admin dashboard is
completely unaffected.

### Which query string parameters does it remove?

It removes all query string parameters from CSS and JS URLs — including `?ver=`,`?
v=`, `?timestamp=`, and any other parameters. It is not limited to just `?ver=`.

### Will this break my website?

No. Removing query strings from static resources is a safe and widely recommended
performance optimization. Your CSS and JS files will still load correctly.

### Does it work with caching plugins?

Yes. It is compatible with all caching plugins.

### Will it improve my PageSpeed or GTmetrix score?

Yes. Tools like Google PageSpeed Insights, GTmetrix, Pingdom, and YSlow flag query
strings on static resources as a performance issue. Removing them helps improve 
your score.

### I need support

Please open a support topic on the [WordPress.org support forum](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources)
and we will be happy to help.

## Reviews

![](https://secure.gravatar.com/avatar/843cf5359b8921da50c84752894b3a359c040f87830a78dd3954aac75568d6fd?
s=60&d=retro&r=g)

### 󠀁[good plugin](https://wordpress.org/support/topic/good-plugin-7097/)󠁿

 [RoJackal](https://profiles.wordpress.org/rojackal/) Avril 2, 2025

good and useful plugin

![](https://secure.gravatar.com/avatar/5eba82187f5b3bb898da2e72a5b6ea95b89c72d2f64b9feaa577877a308068a3?
s=60&d=retro&r=g)

### 󠀁[very useful](https://wordpress.org/support/topic/very-useful-3512/)󠁿

 [Sepi](https://profiles.wordpress.org/sepicompanywork/) Jiyè 31, 2024

good plugin and useful, thanks hope to see updates

![](https://secure.gravatar.com/avatar/590c1a85322729f2345aa128684db6522b37951ea328215b6f501ed8439c0a91?
s=60&d=retro&r=g)

### 󠀁[Good Remove Query Strings!](https://wordpress.org/support/topic/good-remove-query-strings/)󠁿

 [Jimmy Lee](https://profiles.wordpress.org/shirtguy72/) Novanm 1, 2023

Thank You!

![](https://secure.gravatar.com/avatar/44326f9ecffa37d797f3fe2bc5f493ef5574e297439176df27fc47d521d82ff8?
s=60&d=retro&r=g)

### 󠀁[Works like a charm](https://wordpress.org/support/topic/works-like-a-charm-1089/)󠁿

 [Presidency.io](https://profiles.wordpress.org/presidencyio/) Dawout 18, 2017

Hardly ever leave reviews, but this one deserves it. Works like a charm right out
of the box.

![](https://secure.gravatar.com/avatar/0eff1a02b114621a84d70475314dd69b6bfc43994c699bf1c652082a015e06eb?
s=60&d=retro&r=g)

### 󠀁[Plugin Support](https://wordpress.org/support/topic/plugin-support-30/)󠁿

 [Rinku Y](https://profiles.wordpress.org/rinkuyadav999/) Dawout 14, 2017

If you need support, Please create a support topic.

 [ Read all 5 reviews ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/)

## Contributors & Developers

“WP Remove Query Strings From Static Resources” is open source software. The following
people have contributed to this plugin.

Contributors

 *   [ Rinku Y ](https://profiles.wordpress.org/rinkuyadav999/)

“WP Remove Query Strings From Static Resources” has been translated into 1 locale.
Thank you to [the translators](https://translate.wordpress.org/projects/wp-plugins/wp-remove-query-strings-from-static-resources/contributors)
for their contributions.

[Translate “WP Remove Query Strings From Static Resources” into your language.](https://translate.wordpress.org/projects/wp-plugins/wp-remove-query-strings-from-static-resources)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/wp-remove-query-strings-from-static-resources/),
check out the [SVN repository](https://plugins.svn.wordpress.org/wp-remove-query-strings-from-static-resources/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/wp-remove-query-strings-from-static-resources/)
by [RSS](https://plugins.trac.wordpress.org/log/wp-remove-query-strings-from-static-resources/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 2.4

 * Added: Strict file extension checking to ensure only `.css` and `.js` files are
   processed, protecting dynamic PHP scripts.
 * Added: Safely ignores external resources to prevent breaking third-party APIs
   like Google Maps.
 * Improved: Internal code structure and reliability.

#### 2.3

 * Plugin check issues fixed
 * Improved code

#### 2.2

 * Fixed: Replaced unsafe `strtok()` with `explode()` to prevent conflicts with 
   other plugins and WordPress core loops.

#### 2.0

 * Improved: Removed unnecessary class property, filter callback now uses local 
   variable
 * Improved: Strip all query string parameters (not just ?ver and &ver)
 * Improved: Plugin initialised via plugins_loaded hook for correct WP load order
 * Added: Requires PHP header (7.4)
 * Updated: Requires at least bumped to 5.0
 * Updated: Tested up to 7.0
 * Fixed: Typos and grammar in readme
 * Updated: Readme rewritten for better clarity and SEO

#### 1.8

 * Remove additional class

#### 1.7

 * Added additional class

#### 1.6

 * Tested for WP 6.6

#### 1.5

 * Tested for WP 6.3

#### 1.4

 * Compatibility WP 6.0

#### 1.3

 * 23 Feb, 2019
 * Text improved
 * Increase Version

#### 1.2

 * 3 July, 2017
 * Code improved

#### 1.1

 * 3 July, 2017
 * Compatibility issue

#### 1.0

 * 29 June, 2017
 * First Release

## Meta

 *  Version **2.4**
 *  Last updated **3 months ago**
 *  Active installations **3,000+**
 *  WordPress version ** 5.0 or higher **
 *  Tested up to **7.0.6**
 *  PHP version ** 7.4 or higher **
 *  Languages
 * [English (US)](https://wordpress.org/plugins/wp-remove-query-strings-from-static-resources/)
   and [Japanese](https://ja.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/).
 *  [Translate into your language](https://translate.wordpress.org/projects/wp-plugins/wp-remove-query-strings-from-static-resources)
 * Tags
 * [Page Speed](https://hat.wordpress.org/plugins/tags/page-speed/)[performance](https://hat.wordpress.org/plugins/tags/performance/)
   [query strings](https://hat.wordpress.org/plugins/tags/query-strings/)[remove query strings](https://hat.wordpress.org/plugins/tags/remove-query-strings/)
   [static resources](https://hat.wordpress.org/plugins/tags/static-resources/)
 *  [Advanced View](https://hat.wordpress.org/plugins/wp-remove-query-strings-from-static-resources/advanced/)

## Ratings

 5 out of 5 stars.

 *  [  5 5-star reviews     ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/?filter=5)
 *  [  0 4-star reviews     ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/?filter=4)
 *  [  0 3-star reviews     ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/?filter=3)
 *  [  0 2-star reviews     ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/?filter=2)
 *  [  0 1-star reviews     ](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/reviews/)

## Contributors

 *   [ Rinku Y ](https://profiles.wordpress.org/rinkuyadav999/)

## Support

Issues resolved in last two months:

     0 out of 1

 [View support forum](https://wordpress.org/support/plugin/wp-remove-query-strings-from-static-resources/)

## Donate

Would you like to support the advancement of this plugin?

 [ Donate to this plugin ](https://lbcache.com)