Social Media Embed Code Generator
Official embed code for a post from any platform, from its URL alone.
- 100% success
Tool input
Overview
About this tool
Generates the platform’s own embed code for X, Instagram, TikTok, Facebook, LinkedIn, Pinterest, Reddit, Threads, YouTube, Vimeo, Dailymotion and Twitch — in both the documented script form and, where one exists, a script-free iframe for a CMS that strips JavaScript.
Instructions
How to use it
Paste the URL of a single post, video, Reel or Pin. The tool works out the platform and builds the embed code that platform documents.
Script or iframe?
- Blockquote + script is what each platform documents. It renders the real post with avatar, media and live counts, and it loads third-party JavaScript onto your page to do it.
- Iframe, where the platform publishes one, renders the same post in a sandbox with no script on your page. Reach for it in a CMS that strips
<script>tags, in AMP, and anywhere a privacy review has to sign the page off.
Keep the plain link
Every result ends with a plain anchor, and it is not a consolation prize. An embed that fails to load — blocked script, deleted post, account gone private — leaves a hole where your quotation was. A linked quotation degrades into a sentence and a link, which still reads.
Questions
Frequently asked
My X embed renders as plain text.
Almost always the anchor. X’s widget reads the URL from the <code><a></code> inside the blockquote, not from the blockquote itself, and many editors “tidy up” an empty anchor out of existence on save. Paste the code into a raw HTML block rather than a rich-text one.
Do I need one script tag per embed?
No, and you should not. Include each platform’s script once near the end of the page; every blockquote on the page is picked up by it. The second code block in each result is the version without the script for exactly this.
Why does my Twitch embed refuse to play?
Twitch requires the embed URL to name the domain it is served from, in a <code>parent</code> parameter, and it needs one for every domain including localhost. Fill in “Your domain” and the generated code carries it.
The embed became an empty box.
The post was deleted, or the account went private. Meta’s embeds in particular render nothing at all in that case, which is why the plain-link fallback in every result is worth keeping in your page.
Do embeds slow my page down?
Materially, yes — a single X or Instagram embed pulls several hundred kilobytes of script and does its own network requests. Click-to-load placeholders solve the performance problem and the consent problem at once.
Stay sharp
One email a month, when a tool worth your time ships.
No drip sequence, no launch countdowns. Unsubscribe in one click.