How to use the Video Embed Code Generator
- Paste a video link — YouTube (watch, youtu.be, Shorts), Vimeo, Loom, Wistia, Dailymotion, Twitch, Streamable, Google Drive, Facebook or a direct .mp4 file. The platform, ID and start time are read from it.
- Choose a responsive iframe, or the lite version that loads the player only when clicked (much faster pages).
- Set the start and end time, autoplay (always muted — browsers block autoplay with sound), loop, controls and captions.
- Copy the code into an Embed element (Webflow), a Custom HTML block (WordPress) or your page. Options a platform’s player doesn’t support are hidden.
Supported platforms
YouTube (privacy-enhanced mode, start/end, captions, lite mode), Vimeo (including unlisted links with a hash, do-not-track), Loom, Wistia, Dailymotion, Twitch (videos, clips and live channels — Twitch requires the domains you embed on), Streamable, Google Drive (files shared with “Anyone with the link”), Facebook videos and your own MP4/WebM files with the HTML5 <video> element.
Responsive without wrapper hacks
The code uses the CSS aspect-ratio property, so the video fills its container’s width and keeps its shape — no padding-bottom trick needed. Vertical Shorts use 9:16 and are limited in width so they don’t become huge on desktop.
Why the lite version is faster
A regular YouTube embed loads around 1 MB of scripts before anyone presses play, which hurts Largest Contentful Paint and Total Blocking Time. The lite version shows only the video’s thumbnail and a play button; the real player loads on click and starts immediately. Use it whenever a page has more than one video or the video isn’t the first thing people see.
| Option | Parameter |
|---|---|
| Privacy-enhanced mode | youtube-nocookie.com domain |
| Start / end | start, end (seconds) |
| Autoplay | autoplay=1&mute=1 |
| Loop | loop=1&playlist=ID |
| Captions | cc_load_policy=1 |
| Related videos | rel=0 (same channel only) |
Also searched as: youtube embed code generator, vimeo embed code, responsive video embed, loom embed, embed video html, wistia embed code, twitch embed, lite youtube embed.
Tools that pair well with the Video Embed Code Generator
- Google Maps Embed Generator — Show your office, store or event on a Google Map without signing up for an API key.
- Cookie Consent Banner Generator — Add a cookie consent banner to any site — Webflow, WordPress, Shopify or plain HTML — without a paid plugin.
- Page Speed Test — Run Google Lighthouse on any URL for mobile or desktop.
- OG Image Generator — Create a polished link-preview image for Facebook, LinkedIn, X, Slack and WhatsApp in seconds — pick a template, type your title, add a logo, then download the PNG and matching meta tags.