Skip to content
Postkit

Video. A responsive HTML video player with caption support.

  • Media
  • Interactive
  • Stability · Initial
  • ::postkit-video
A quick tour of the portable publishing contract.

Usage.

<Video
  src="data:video/mp4;base64,"
  poster="/component-preview.svg"
  title="Postkit in two minutes"
  caption="A quick tour of the portable publishing contract."
  duration="2:00"
  decorative
/>

Props. Always in step with the code.

PropTypeDefaultDescription
srcRequiredstringNoneThe video file URL.
titleRequiredstringNoneAn accessible title for the video.
posterstringNoneThe preview image URL.
captionstringNoneVisible supporting text below the player.
aspectRatiostring"16 / 9"A CSS aspect ratio such as 16 / 9.
preload"none" | "metadata" | "auto""metadata"Browser preload behavior.
captionsstringNoneThe captions track (a WebVTT file URL).
captionsLangstringNoneThe language of the captions track, such as en.
durationstringNoneThe running time, such as 0:24 or 1:02:03, shown with the caption.
decorativebooleanNoneMarks a video without speech or meaningful sound, such as a silent loop, so it needs no captions track.
Appearance
size"sm" | "md" | "lg""md"The component density and type scale.
variant"outline" | "subtle" | "plain""subtle"The component visual treatment.

Every component also takes unstyled and the part-styling props. Change a default for your whole site with defaults in createPostkit. Part styles

Anatomy. Every part is yours to restyle.

Every part

  • root
  • frame
  • player
  • caption
  • fallback
  • duration
  • number

Renderers. One component, everywhere you publish.

  • Headless @postkit/reactSupported
  • Chakra @postkit/chakraSupported
  • Email @postkit/emailSupported
  • Astro @postkit/astroStatic
  • Web components @postkit/elementsPlanned
Postkit

Richer posts, written once, right everywhere.

© 2026 Postkit. MIT licensed.
LicensingPrivacy