(video: …)
Embeds a video from YouTube, Vimeo or a local file by URL or filename
Attributes
autoplay |
caption |
controls |
class |
height |
loop |
muted |
playsinline |
poster |
preload |
style |
width |
Supported video sources
YouTube
Embedded YouTube video by video URL:
The following link YouTube link formats are recognized:
Basic video URLs:
- https://www.youtube.com/watch?v=lLuc6rtWkrM
- https://www.youtube.com/embed/lLuc6rtWkrM
- https://youtu.be/lLuc6rtWkrM
- https://www.youtube-nocookie.com/embed/d9NF2edxy-M
URLs with additional query parameters:
- https://www.youtube.com/watch?v=d9NF2edxy-M&t=10
- https://www.youtube-nocookie.com/watch?v=d9NF2edxy-M&t=10
- https://www.youtube.com/embed/d9NF2edxy-M?start=10
- https://www.youtube-nocookie.com/embed/d9NF2edxy-M?start=10
Playlists:
- https://www.youtube.com/embed/videoseries?list=PLj8e95eaxiB9goOAvINIy4Vt3mlWQJxys
- https://www.youtube-nocookie.com/embed/videoseries?list=PLj8e95eaxiB9goOAvINIy4Vt3mlWQJxys
- https://www.youtube.com/playlist?list=PLj8e95eaxiB9goOAvINIy4Vt3mlWQJxys
- https://www.youtube-nocookie.com/playlist?list=PLj8e95eaxiB9goOAvINIy4Vt3mlWQJxys
Vimeo
Embedded Vimeo video by video URL:
Local and remote videos
You can now embed videos from the local or from remote servers.
The video will be muted automatically if autoplay
is enabled and muted
is not defined. To start autoplay with sound, use it as in the following example:
Options
Caption
<iframe>
size
Custom CSS class
New attributes
The video tag now supports some attributes of the HTML <video>
element: autoplay
, controls
, loop
, muted
, poster
, preload
These new attributes are not supported by video providers such as YouTube and Vimeo.
Version 2's youtube
and vimeo
tags
To keep your content compatible with older Kirby versions, we still have the old youtube
and vimeo
KirbyTags. We recommend switching to the new video
tag though.