Is jQuery Migrate Still Needed in WordPress? (Spoiler: Probably Not)

Check your site’s page source and search for jquery-migrate. You’ll likely find a 10 KB JavaScript file loading on every page: jquery-migrate.min.js. It exists for one reason — to keep old jQuery code working with new jQuery versions.

WordPress shipped jQuery Migrate by default to smooth the transition from jQuery 1.x to jQuery 3.x. That transition started years ago. If your plugins and theme are reasonably up to date, this compatibility script is doing nothing except adding weight to every page load.

What is jQuery Migrate?

jQuery Migrate is a compatibility layer. When jQuery updates to a new major version, some older functions get removed or changed. jQuery Migrate intercepts calls to those deprecated functions and makes them work anyway, logging console warnings about the outdated code.

WordPress 5.6 (December 2020) shipped with jQuery 3.5. To prevent older plugins from breaking, WordPress included jQuery Migrate as a safety net. It catches deprecated function calls like .live(), .bind(), .size(), and old AJAX shorthand methods, and translates them into their modern equivalents.

The file is about 10 KB minified. Not huge, but it’s a render-blocking script that loads before jQuery itself can execute. And the deprecation warnings it handles are from jQuery 1.x patterns — code that any actively maintained plugin abandoned years ago.

Why should you care?

10 KB of JavaScript on every page. It loads as a dependency of jQuery itself, meaning it’s render-blocking. Removing it eliminates one script from your critical rendering path.

It masks outdated code. jQuery Migrate silently fixes deprecated code instead of letting it break visibly. That sounds helpful, but it means you might be running plugins with seriously outdated JavaScript without knowing it. Removing Migrate forces those issues to surface so you can update the offending plugins.

It runs on every page, needed or not. Even if one obscure plugin needs jQuery Migrate on one specific page, WordPress loads it sitewide. That’s the worst kind of performance overhead.

Modern WordPress is moving away from jQuery. Gutenberg uses React. Modern themes use vanilla JavaScript. The trajectory is clear — jQuery dependency in WordPress is shrinking, and jQuery Migrate for jQuery 1.x patterns is even more obsolete.

The quick fix

// Remove jQuery Migrate on the frontend
add_action( 'wp_default_scripts', function( $scripts ) {
    if ( ! is_admin() && isset( $scripts->registered['jquery'] ) ) {
        $script = $scripts->registered['jquery'];
        if ( $script->deps ) {
            $script->deps = array_diff( $script->deps, ['jquery-migrate'] );
        }
    }
});

This removes jQuery Migrate from the frontend only. The WordPress admin keeps it loaded to avoid breaking anything in the dashboard.

Before you remove it: Open your site with browser DevTools, go to the Console tab, and look for yellow deprecation warnings mentioning “jQuery Migrate.” If you see warnings, identify which plugin or theme is causing them and update it first. If the Console is clean, you’re safe to remove Migrate.

The one-click solution

OvKit includes Remove jQuery Migrate under Features → Performance. One toggle removes the compatibility script from the frontend while keeping it available in the admin area. OvKit handles the dependency chain correctly so jQuery itself continues working.

What happens after you fix this?

  • 10 KB less JavaScript on every page load
  • One fewer render-blocking script in your critical path
  • Faster jQuery initialization — no compatibility layer processing
  • Outdated plugins get exposed — you’ll know what needs updating
  • PageSpeed improvement — contributes to better Total Blocking Time scores

FAQ

How do I know if my site needs jQuery Migrate?

Open your site in Chrome, press F12 to open DevTools, go to the Console tab, and refresh the page. If you see any yellow warnings containing “JQMIGRATE” — a plugin or theme is using deprecated jQuery functions. Update that plugin first, then try removing Migrate. If the Console is clean, you’re safe.

Will removing jQuery Migrate break my contact forms or sliders?

Modern versions of popular plugins (Contact Form 7, WPForms, Slider Revolution, etc.) all work with jQuery 3.x without needing the Migrate script. If you’re running current versions, no breakage. If you’re running a plugin that hasn’t been updated in 3+ years, it might break — but that plugin is a security risk anyway and should be replaced.

Does this affect the Gutenberg editor?

No. Gutenberg is built on React, not jQuery. The block editor doesn’t use jQuery at all, so removing jQuery Migrate has zero impact on your editing experience.


Related reads: