How to embed Instagram in WordPress without an API key
Three ways to show a public Instagram post on a WordPress page without a Facebook developer app or API token, and when to use each one.
Quick answer: paste the post's public link into the embed generator, copy the blockquote code and add it in a Custom HTML block. Instagram's own script draws the post, so you need no API key.
Why the built-in embed often fails
WordPress can turn an Instagram link into an embed through oEmbed, but Meta now requires a registered Facebook app and an access token for that request. Without one, pasting the link in the editor shows a plain link or an error. That is why many sites switch to one of the methods below.
Method 1: the embed code in a Custom HTML block
- Open the post on Instagram, copy the link from the address bar (a public post, reel or video).
- Paste it into the embed code generator and choose whether to show captions and the maximum width.
- Copy the blockquote code and paste it into a Custom HTML block. Instagram's
embed.jsturns the blockquote into the full post when the page loads.
This is free and works on any site, not only WordPress. The cost is that you paste code for every post.
Method 2: an iframe
The generator also gives an iframe version. It loads the post inside a frame and does not need the script, which helps on pages where scripts are blocked. The frame has a fixed height, so check how it looks on a phone.
Method 3: a block plugin
A plugin such as InstaBlocks adds an Instagram block to the editor. You paste the link, and it handles the embed and offers style presets without an API key. This is the easiest option if you embed posts often.
Things to check
- Only public content works. Profiles, stories and posts from private accounts cannot be embedded.
- Remove share tracking. Links copied from the app carry parameters such as
igsh. They are not needed. The generator strips them. - Page speed. Each embed loads Instagram's script and images. Embed only what you need and avoid dozens on one page.
- Privacy. Embeds contact Instagram when the page loads, so mention it in your privacy policy and consent banner if you use one.
Want to change the look? The embed style generator outputs CSS for width, border and shadow.