Skip to main content
GitHub
1 min read

Components

Video

Embed videos from YouTube, Vimeo, and Loom

Embed videos from YouTube, Vimeo, and Loom with a responsive player and optional caption.

YouTube

A YouTube video embedded with the Video component
<Video client:load url="https://www.youtube.com/watch?v=dQw4w9WgXcQ" title="Demo video" caption="A YouTube video" />

Vimeo

<Video client:load url="https://vimeo.com/123456789" title="Vimeo video" />

Loom

<Video client:load url="https://www.loom.com/share/abc123def456" title="Loom recording" caption="Screen recording" />

Supported URL Formats

ProviderFormats
YouTubeyoutube.com/watch?v=ID, youtu.be/ID, youtube.com/embed/ID
Vimeovimeo.com/ID, player.vimeo.com/video/ID
Loomloom.com/share/ID, loom.com/embed/ID

Props

urlstringrequired

Video URL from YouTube, Vimeo, or Loom

titlestring

Accessible title for the iframe (defaults to provider name)

captionstring

Caption text displayed below the video

client:loaddirectiverequired

Required Astro directive for client-side interactivity