Embed a single video

How to use the Capsule Player embed code

You can copy the embed code for any video in your Capsule Dashboard like this:

Here's an example of an embed code:

<div>
  <script>
    (function(c,a,p,s,u,l,e){c["_capsulePlayerIdent"]=p;c[p]=c[p]||function(){
    (c[p].q=c[p].q||[]).push(arguments);e=a.querySelector("script[data-capsule='"+p+"']");
    if(!e){u=a.createElement("script");u.async=1;u.src=s;u.dataset["capsule"]=p;
    l=a.currentScript?.parentElement||a.body;l.appendChild(u);}}})
    (window,document,"capsulePlayer","https://embed.capsule.video/player.js");
    capsulePlayer({
      slug: 'your-capsule-slug',
      id: 'nxOsT1t1vsdk',
      el: document.currentScript.parentElement
    })
  </script>
 </div>

The follow parameters can be used to customize the embedded player:

Last updated