Skip to main content
The PolyEmbed WordPress plugin adds a [polyembed] shortcode. It fills in the post title for you, builds the iframe, and includes the resize and collapse script.

Install the plugin

1

Get the plugin

Email contact@polyembed.io for the current polyembed plugin ZIP.
2

Upload it

In WordPress, go to Plugins > Add New > Upload Plugin, choose the ZIP, and click Install Now.
3

Activate it

Click Activate. The plugin is called PolyEmbed Widget in your plugin list.

Add the shortcode

Copy the shortcode from the WordPress tab on your widget page:
Shortcode
Then add it where the widget should appear:
In the block editor, add a Shortcode block and paste the shortcode.

Add keywords for tighter matches

The shortcode uses the post title automatically. Add keywords to improve matching:
To use each post’s tags as keywords in a template:
single.php
See the shortcode reference for every attribute.

Signed snippets

If your widget page shows a shortcode with d, kv and sig attributes, copy it exactly. Those attributes sign the snippet to your domain. If you rotate the embed key, replace the shortcode everywhere you use it. See Embed security.

Caching and security plugins

  • Page caches are fine: the widget does its matching inside the iframe on every load.
  • If a security plugin sets a Content-Security-Policy, allow frame-src https://iframe.polyembed.io.
  • If an optimization plugin rewrites iframes (for example to lazy-load them), make sure it keeps the referrerpolicy attribute and the script that follows the iframe.