Black Friday Black FridayUp to 85% off all WP Ghost plans.48 months from $49, or pay once for lifetime. SHOP NOW

How Do I Hide the WordPress Version?

Moved

This tutorial has moved to the new WP Ghost Knowledge Base where each feature is presented in detail.

View on new site

Switch on Hide Version from Images, CSS and JS and Random Static Number in WP Ghost > Tweaks > Hide Options, and add Hide WordPress Generator META Tags for the generator tag. Without them, WordPress shows version numbers on every CSS and JavaScript file and in the generator tag.

Where does WordPress expose version numbers?

WordPress reveals your version in multiple places throughout every page on your site. The most visible one is the <meta name="generator" content="WordPress 6.7.1" /> tag in your HTML head. But that’s not the only place.

Every enqueued CSS and JavaScript file gets a ?ver= parameter appended to its URL. Your page source ends up showing entries like style.css?ver=6.7.1, woocommerce.css?ver=9.5.1, and elementor.min.js?ver=3.25.0. Those parameters don’t just reveal the WordPress core version, they expose the exact version of every plugin and theme on your site. Attackers cross-reference these version numbers against vulnerability databases to find known exploits without needing to scan anything.

Why should you hide WordPress version numbers?

Version numbers give attackers a shortcut. Instead of probing your site, they read your source code, see which plugin version you run, look it up in a public vulnerability database and launch a targeted exploit. Without version numbers, automated bots have nothing to look up.

The generator meta tag is also the primary signal that tools like Wappalyzer, BuiltWith, and other CMS detectors use to confirm WordPress. Even if you’ve changed all your paths, this one tag can override everything. A complete hack prevention setup removes it.

How do I hide the WordPress version with WP Ghost?

WP Ghost provides two features that work together: stripping version numbers from the frontend, and replacing them with a random cache-busting number to prevent browser caching issues.

Step 1 – Hide Version from Images, CSS and JS

Go to WP Ghost > Tweaks > Hide Options. Switch on Hide Version from Images, CSS and JS. Click Save.

After saving, the real ?ver= numbers disappear from the CSS, JavaScript and image URLs in your page source. Where your source showed style.css?ver=6.7.1, it now shows style.css, or style.css with a random number once you do Step 2. To remove the <meta name="generator"> tag as well, switch on Hide WordPress Generator META Tags in the same tab.

Step 2 – Enable Random Static Number

Removing version parameters entirely can cause a caching problem. Browsers use the ?ver= parameter to know when a file has changed. Without it, browsers may keep serving old cached CSS and JavaScript after you update a plugin or theme, leading to broken layouts.

The fix: go to WP Ghost > Tweaks > Hide Options and switch on Random Static Number. This replaces the real version number with a random identifier (for example, style.css?rnd=37342). Browsers see a unique parameter and fetch the latest file, but the number reveals nothing about your software versions.

Enable both features together. “Hide Version” removes the real version numbers. “Random Static Number” replaces them with a non-informative identifier that keeps browser caching working correctly.

How do I verify that version numbers are actually hidden?

After saving, clear all caches (your WordPress caching plugin, CDN, and browser cache). Then open your site in a private browser window and view the page source. Search for ?ver= and generator. If the features are working correctly, you won’t find any real version numbers or generator meta tags.

You can also run WP Ghost > Security Check > Start Scan to confirm the version-hiding task is marked as complete.

For the full version-hiding tutorial with screenshots and troubleshooting, see the Hide WordPress Version guide.

What else should I hide along with version numbers?

Version numbers are just one piece of the WordPress fingerprint. For a thorough cleanup, you should also hide IDs from META tags to remove plugin and theme identifiers from element IDs, change and hide plugin paths so directory names don’t reveal your plugin stack, and change and hide theme paths so your theme name doesn’t appear in the source. Together with version hiding, these features make your WordPress installation extremely difficult to identify.

For a guide to removing every detection signal, see the hide from theme detectors tutorial.

Frequently asked questions

Does this also remove the meta generator tag?

Not this option. Hide Version from Images, CSS and JS handles the version parameters; the generator tag goes with Hide WordPress Generator META Tags in the same Tweaks > Hide Options tab, which removes every generator meta tag in the page, including the ones plugins add.

Does this hide plugin and theme versions, not just the WordPress core version?

Yes. WP Ghost strips the ?ver= parameter from all enqueued assets, not just WordPress core files. That includes every plugin stylesheet, every plugin script, and your theme’s CSS and JavaScript files. All version numbers are removed in one action.

Will my CSS or layout break after hiding versions?

It can, if you don’t also enable Random Static Number. Without any version parameter, browsers may keep serving old cached files after plugin updates. The Random Static Number feature replaces real versions with a random identifier, keeping cache-busting functional. Enable both features together and clear all caches after saving.

Does hiding version numbers affect SEO?

No. Search engines don’t use version parameters or generator meta tags for ranking. Removing them has zero impact on indexing, crawling, or search visibility. Your content, sitemaps, and canonical URLs remain unchanged.

Does this work with WooCommerce?

Yes. WooCommerce’s CSS and JavaScript files have their version parameters stripped like all other assets. WP Ghost is fully compatible with WooCommerce.

Does WP Ghost modify WordPress core files?

No. WP Ghost strips version parameters from the HTML output at runtime through WordPress filters. The actual CSS, JavaScript, and PHP files on disk are untouched. Disabling the features restores all original version parameters instantly.