Performance module Free feature

Disable oEmbed

Removes wp-embed.js and the oEmbed discovery links, and switches off the endpoint other sites use to embed your posts.

What it does

Removes the embed handler and its discovery links

Disable oEmbed is a Vectro performance feature that removes the wp-embed.js script and the oEmbed discovery links from your pages and turns off the oEmbed endpoint that lets other sites embed your posts, while embeds from the providers WordPress supports keep working.

oEmbed is the mechanism that turns a pasted YouTube or Twitter URL into an embedded player or card. To support it, WordPress loads wp-embed.js on every page and adds discovery links to your head that let other sites embed your content in return.

This feature removes both. The script stops loading and the discovery links stop being printed.

Embeds from the providers WordPress supports out of the box, such as YouTube, Vimeo and Spotify, keep working, because WordPress already knows their endpoints. What stops is discovery for everything else: a link to a site WordPress does not list as a provider, such as another WordPress blog, is no longer looked up for embed data and stays a plain link.

Why it matters

Most sites carry it without ever using it

Every page on a default WordPress install requests wp-embed.js, whether or not that page contains a single embed. On a content site that only ever publishes text and images, that is a request and a parse repeated on every page view for a feature that never fires.

The discovery links have a separate consideration. They exist so other sites can embed your posts, which also means they advertise an endpoint that returns structured data about your content. If you have no interest in being embedded elsewhere, removing them is one fewer thing exposed.

One fewer script per page
wp-embed.js stops loading on every page regardless of whether the page contains an embed.
Discovery links removed
The oEmbed discovery links stop being printed into your document head.
Known providers keep working
YouTube, Vimeo, Spotify and the other providers WordPress lists still embed. Only discovery for unlisted sites stops.
Reversible instantly
Turn the toggle back off and embeds return with no lasting change to your content.

How to use it

Check for embeds, then disable

1
Check whether you embed other WordPress sites
Links to sites WordPress does not list as an oEmbed provider, including most other WordPress blogs, will show as plain links while this is on.
2
Open the Performance module
Go to Vectro > Performance in wp-admin.
3
Toggle Disable oEmbed on
wp-embed.js stops loading and the discovery links stop being printed.
4
Save Performance Settings and clear your page cache
Cached pages keep the old markup until they are regenerated.
5
Spot-check a few posts
View a handful of posts logged out to confirm nothing that should be embedded has turned into a plain URL.

Technical detail

What is removed

Vectro dequeues the wp-embed script, removes the oEmbed discovery link action from the head, and removes the oEmbed host JavaScript filter. It also disables the REST route that serves oEmbed data about your posts, and turns off oEmbed discovery, so only providers WordPress already lists are embedded.

Existing embeds already saved in post content are not modified. If you disable the feature later, they render again exactly as before.

Script removed
wp-embed.js
Head cleanup
oEmbed discovery links are no longer printed.
REST route
The oEmbed data endpoint is disabled.
Post content
Not modified. Saved embeds are untouched in the database.
Effect on embeds
Providers WordPress lists, such as YouTube, Vimeo and Spotify, still embed. Links to unlisted sites stay plain links.
Block editor
The oEmbed REST routes are removed, including the proxy the block editor uses to preview embeds, so new embed blocks may not preview while the feature is on.
Reversible
Turning the toggle off restores embeds immediately.

Compatibility

Vectro detects these and steps aside

Perfmatters
Vectro switches its own oEmbed removal off while Perfmatters is active.
Asset CleanUp
Vectro steps aside so Asset CleanUp keeps sole control of the embed script.

You can override any automatic deferral from the Compatibility panel in Vectro’s dashboard if you would rather Vectro handle it.

Questions

Frequently asked

What does disabling oEmbed do in WordPress?

Disabling oEmbed removes the wp-embed.js script and the oEmbed discovery links from your pages and turns off the endpoint other sites use to embed your posts. Pasted YouTube, Vimeo or Spotify URLs still embed, because WordPress already knows those providers.

Does Vectro disable oEmbed work with Perfmatters?

No – if Perfmatters is active, Vectro detects it and disables its own oEmbed removal automatically. Perfmatters handles it instead so the script is only dequeued once.

How do I disable oEmbed in Vectro?

Go to Vectro > Performance in wp-admin, toggle Disable oEmbed on, then clear your page cache. Check a few posts afterwards to confirm nothing that should be embedded has become a plain URL.

Is disabling oEmbed in Vectro free or Pro?

Yes, Disabling oEmbed is free. It is included in the free Vectro plugin on WordPress.org with no account required.

Will disabling oEmbed break my existing YouTube embeds?

No – YouTube is one of the providers WordPress lists, so YouTube URLs keep embedding. What stops working is embedding from sites WordPress does not list, which stay plain links while the feature is on. Your post content is not modified, so turning the toggle off restores those immediately.

Related features

Strip the rest of the defaults

Vectro Pro adds minification and WooCommerce script optimisation for shop-heavy sites. See Pro plans

Download Vectro free on WordPress.org

27 features across Security, Performance and Maintenance. No account required, no expiry, unlimited sites.

Scroll to Top