Embed your video

After uploading a video to FastPix, you can either embed it directly with a ready-to-use player or stream it using your own custom player. This guide walks you through both options.


Get your playbackId

Every video has a unique playbackId used for embedding and playback.

To find it:
Go to Dashboard > Media> [Your Video] > Embed & Share

You’ll see:

  • A copyable iframe embed code
  • The direct .m3u8 streaming URL
  • The raw playbackId


Choose your method

FastPix supports both playback workflows:

Use the iframe embed code if:

  • You want to quickly add a video player to your webpage
  • You don’t need to customize the playback experience or build your own controls

Use the streaming URL if:

  • You're building a web, mobile, or OTT app that uses a custom video player
  • You need full control over playback, analytics, or UI design


Option 1: Embed with iframe

The iframe method is ideal for quickly displaying a video without writing any player code. FastPix hosts the player and handles playback, buffering, and ABR automatically.


Paste the following code into your HTML page:

<iframe 
  src="https://play.fastpix.io/?playbackId=abc123&autoplay=true&muted=true&loop=true&hide-controls=true" 
  width="640" 
  height="360" 
  frameborder="0" 
  allow="autoplay; fullscreen" 
  allowfullscreen> 
</iframe> 

Playback options

You can control the behavior and appearance of the embedded player using URL parameters:

OptionDescription
autoplay=trueAutomatically starts playback when the page loads
muted=trueMutes audio on load (required for autoplay in most browsers)
loop=trueRepeats the video endlessly
hide-controls=trueHides default playback controls (play/pause bar, etc.)
enableVideoClick=trueAllows interaction or redirection on video click
aspect-ratio=21/9Sets the aspect ratio to cinematic widescreen (you can adjust it)

Make it responsive

To embed a responsive video that scales on all screen sizes:

<div style="position: relative; padding-top: 56.25%;">
  <iframe src="https://play.fastpix.io/?playbackId=abc123" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%;" frameborder="0" allow="autoplay; fullscreen" allowfullscreen />
</div>

Option 2: Stream via streaming URL

Use this method if you're building a custom player, in a web app, mobile app, or OTT environment. FastPix provides a ready-to-use .m3u8 HLS stream for each video.

Streaming URL format

https://play.fastpix.io/hls/abc123.m3u8

Replace abc123 with your video’s playbackId.


Compatible with:

  • HLS.js or Shaka Player (Web)
  • AVPlayer (iOS/macOS)
  • ExoPlayer (Android)
  • Native players on smart TVs and OTT devices

The stream uses adaptive bitrate, so quality adjusts based on the viewer’s bandwidth automatically.


📘

PLEASE NOTE

  • Autoplay requires muted=true to work reliably across browsers
  • Use the correct aspect ratio or fixed dimensions to avoid black bars
  • Always test playback on different browsers and devices

Best practices

To ensure a smooth playback experience for your users, follow these recommended practices after embedding your FastPix video.

  • Test across environments: Check playback on major browsers (Chrome, Safari, Firefox, Edge) and on both desktop and mobile devices to catch compatibility issues early.

  • Make it responsive: Wrap the iframe in a CSS-based container to maintain aspect ratio across screen sizes. This avoids layout shifts or black bars.

  • Respect autoplay rules: Most browsers block autoplay unless the video is muted. Always use muted=true when enabling autoplay=true.

  • Support accessibility: If your video includes speech, add captions or a transcript to improve accessibility and boost SEO performance.


Common use cases for embedded videos

FastPix makes it easy to deliver high-quality playback for a wide range of business and creative needs. Here are some of the most common scenarios where embedding video adds real value:

  • Product demos on landing pages: Let users see your product in action without clicking away.
  • Customer testimonial showcases: Build trust with real user feedback presented through short video clips.
  • Tutorials and how-to guides: Help users onboard faster with visual walkthroughs in your docs or support center.
  • Creative portfolios: Showcase animations, short films, or reels without relying on YouTube or Vimeo.
  • Event highlights and webinar replays: Let visitors watch missed sessions directly on your site.
  • Background or hero section videos: Use autoplaying, muted, looping videos to enhance landing page visuals.

Troubleshooting

If something doesn't look right or your video isn’t working as expected, here are a few quick things to check:

  • Video not playing: Confirm that the playbackId is correct and the video is still available in your FastPix workspace.
  • Autoplay not working: Ensure muted=true is included in the embed URL, it's required for autoplay to function in most browsers.
  • Aspect ratio issues: Make sure your aspect-ratio parameter or iframe dimensions match the video’s native resolution to avoid stretching or black bars.