Performance & Asset Loading

When Ultimate Cursor loads its scripts, how it avoids loading unnecessarily, and how it stays compatible with caching plugins.

By the end of this page, you'll understand exactly when Ultimate Cursor loads scripts on your site, and why it won't conflict with your caching setup.

Applies to Ultimate Cursor 2.3.1+.

When scripts actually load

The cursor script only loads on a page if you've actually configured a cursor (a type or effect is set, or multiple cursors are enabled). The background script only loads if a background is enabled and — with multiple configurations — at least one config's scope matches the current page. If neither applies, nothing extra loads.

How scripts are loaded

Both scripts load in the footer with defer, so they never block initial page rendering. Script URLs include a cache-busting version based on file modification time, so updates show up immediately even behind a CDN or cache plugin. Settings are passed to the frontend as typed JSON (not string-serialized), which avoids a class of bugs where numeric settings get corrupted into strings.

Cache-plugin compatibility

Ultimate Cursor's scripts are automatically excluded from:

  • WP Rocket's defer/combine/delay-JS features
  • LiteSpeed Cache's JS combine
  • Autoptimize's JS optimization
  • W3 Total Cache's minify

The frontend script tag also includes crossorigin="anonymous", which some CDN/Cloudflare configurations require to load the script correctly. You don't need to add any exclusion rules yourself — this is automatic.