Skip to main content

HTML Video Generator

API reference

Generate a <video> player tag — set the source, poster image, size, controls, autoplay, loop, muted and preload options, then copy the ready-to-use HTML. Free, instant, no AI involved.

Input

Settings

Most browsers only autoplay muted video.

Add custom CSS classes to the element. Separate multiple classes with spaces.

Output

Enter a video URL to preview the player.

The real generated tag, isolated in a Shadow DOM. Remote files load only if the host allows hotlinking.

HTML
 
Was this helpful?

More ways to use this tool

REST API

curl -X POST https://api.iotools.cloud/v1/tool/html-generator/video \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "customSrc": "https://example.com/clip.mp4",
    "customPoster": "",
    "customWidth": "",
    "customHeight": "",
    "customControls": "true",
    "customAutoplay": "",
    "customLoop": "",
    "customMuted": "",
    "customPlaysinline": "",
    "customPreload": "metadata",
    "customClasses": ""
  }'

Swap in your own key from your account. The tool's fields are the body — no wrapper.

Ask an AI agent

Use the IOTools `html-generator__video` tool (HTML Video Generator) on this input:

YOUR_INPUT_HERE

Paste this at any agent connected to the IOTools MCP server, then add your input.

Embed widget

<iframe
  src="https://iotools.cloud/embed/html-generator/video/"
  width="100%" height="520" frameborder="0" scrolling="no" loading="lazy"
  title="HTML Video Generator — iotools.cloud"
  sandbox="allow-scripts allow-forms allow-same-origin allow-downloads allow-popups allow-popups-to-escape-sandbox"
  allow="clipboard-write"
  style="width:100%;border:1px solid #e5e7eb;border-radius:12px;overflow:hidden"></iframe>
<script src="https://iotools.cloud/embed.js" async></script>

Drop this into your own page — free, no key required, just a link back.

Cost per API/MCP callFrom 5 credits
Need more credits?View pricing

Also available with

Guides

Build a ready-to-paste <video> tag — set the source, poster image, size, controls, autoplay, loop, muted and preload options, then copy the generated HTML.

Runs entirely in your browser: no AI call, no credits, no network round-trip.

How to use it

  1. Enter the Video URL and, optionally, a Poster Image URL shown before playback.
  2. Set a width/height and toggle Show controls, Autoplay, Loop, Muted and Play inline.
  3. Check the Live preview — the real player, rendered from the generated tag.
  4. Copy or download the generated HTML.

Browsers generally block autoplay with sound, so combine Autoplay with Muted (and Play inline for iOS) for background videos. A fallback download link is included inside the element for browsers that can't play it.

htmlvideoplayergenerator

Love the tools? Lose the ads.

One payment clears every ad from your account, for good. No subscription, no tracking.