HTML poster Attribute

Beginner
5 min read
Updated: Oct 2026
3 examples
Live preview

Definition and Usage

The poster attribute on <video> is a URL to an image shown while the video is downloading and before playback starts. It gives users a clear thumbnail instead of an empty or black player box.

If you omit poster, MDN notes that nothing useful is shown until the first frame is available — then that frame acts as the poster. Pair with controls, src or <source>, and often preload.

Baseline · Widely available.

Not deprecated and not experimental. Stable across modern browsers since about July 2015. Applies to <video> only.

Decorative preview — not a caption.

Poster is an image URL, not text. Describe the video elsewhere (nearby heading, transcript, or accessible name) so the meaning is clear without relying on the picture alone.

HTML Syntax

syntax.html
<video poster=" url">…</video>

url is the image address (relative or absolute). Equivalent JS: video.poster = "/images/thumb.png".

Attribute Values

The value is a single image URL. Common patterns:

Value / patternDescriptionTry it
/path/image.pngRelative URL on your site (most common)Try it
https://…Absolute URL (CDN or another origin)Try it
+ preload="none"Show a thumbnail while delaying the video fileTry it
Omitted / emptyNo custom poster — first available video frame is used laterTry it

Live Preview

Switch posters or remove the attribute. Reload the player if you already pressed play — the poster is clearest before playback.

poster

Sample clip from /video/count.mp4. Poster images load separately from the video file.

Video

poster="/images/apple.png"

HTML Examples

Short, copy-ready snippets. Use Try It Yourself for a live editor.

Example 1 — Basic Video Poster

Show a thumbnail before the user presses play.

HTML
<video width="400" height="225" controls playsinline
       poster="/images/apple.png">
  <source src="/video/count.mp4" type="video/mp4">
  Your browser does not support the video element.
</video>
Try It Yourself

How It Works

  1. poster points at a still image URL.
  2. The browser paints that image in the video box before playback.
  3. <source> supplies the MP4 separately from the poster.
  4. controls lets the user start playback and replace the poster with video frames.

Example 2 — Poster with preload="none"

Keep a visible thumbnail while hinting the browser not to fetch the video early.

HTML
<video width="400" height="225" controls playsinline
       poster="/images/javascript.png"
       preload="none">
  <source src="/video/count.mp4" type="video/mp4">
  Your browser does not support the video element.
</video>
Try It Yourself

How It Works

  1. preload="none" hints: do not download the video yet (browser may still ignore the hint).
  2. poster is a separate image request — it can still load for a preview.
  3. On play, the browser fetches the video and swaps in frames.
  4. Set width/height to reduce layout shift while media loads.

Example 3 — With vs Without Poster

Compare a custom thumbnail to the browser’s default (first frame later).

HTML
<p>With poster</p>
<video width="320" height="180" controls playsinline
       poster="/images/apple.png" preload="metadata">
  <source src="/video/count.mp4" type="video/mp4">
</video>

<p>Without poster</p>
<video width="320" height="180" controls playsinline
       preload="metadata">
  <source src="/video/count.mp4" type="video/mp4">
</video>
Try It Yourself

How It Works

  1. With poster — a chosen image appears immediately in the player.
  2. Without poster — you often see a blank/black box until a frame is ready.
  3. MDN default — once the first frame is available, that frame becomes the stand-in.
  4. Pick a useful still that matches the video’s aspect ratio for a polished look.

Edge Cases & Pitfalls

Most surprises come from broken image URLs, wrong aspect ratio, or expecting the poster to return after pause.

scope

Video only

poster is not valid on <audio>. Use it only on <video>.

404

Broken poster URL

If the image fails to load, you lose the custom thumbnail. Check the path the same way you would for <img src>.

pause

Poster usually does not return

After play starts, pausing shows the current frame — not the original poster image.

ratio

Match width and height

Set width and height (or CSS aspect-ratio) so the poster and video share the same box and avoid layout jump.

lazy

Lazy loading delays poster too

Per MDN: when loading="lazy" is set on video, the poster resource is fetched only once the video is near or in the viewport.

Browser Support

poster is an HTML attribute on the video element in the browser. It is not a Node.js, Deno, or Bun API.

✓ Widely available

poster

Supported in all modern browsers for HTML video. Use a lightweight image that matches the video aspect ratio.

97% Global support (approx.)
Google Chrome All modern
Full support
Mozilla Firefox All modern
Full support
Apple Safari All modern
Full support
Microsoft Edge All modern
Full support
Opera All modern
Full support
Samsung Internet Modern
Full support
Internet Explorer 9+
Supported
poster Widely supported

Bottom line: Safe to use on every modern video embed. Prefer a small still image so the preview loads quickly.

Key Takeaways

  • Role: image URL shown before video playback.
  • Element: <video> only — not audio.
  • Separate fetch from the video file — works well with preload="none".
  • Omit it and the first available frame becomes the stand-in later.

One line: poster is a preview image URL for <video> until playback starts.

Frequently Asked Questions

On a video element, poster is a URL to an image shown while the video is downloading or before playback starts. If you omit it, nothing useful shows until the first video frame is available, then that frame is used.
Only the video element. The audio element has no poster attribute.
It is shown until playback begins (or enough data is ready to show a frame). Once the user plays, the video frames replace the poster. Pausing later typically shows the current frame, not the poster again.
Any image format the browser can display in an img context — commonly PNG, JPEG, WebP, and GIF. Prefer a lightweight still that matches the video aspect ratio.
poster is a separate image fetch. With preload="none", the video file itself may wait, but the poster image can still load so users see a thumbnail. Autoplay usually needs video data and overrides a none preload intent.
No. It is a standard HTML attribute on video and is Baseline widely available across modern browsers.

Next: preload

Hint how much of the video or audio to fetch before play.

preload tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful