Responsive Youtube embeds with Bootstrap

Here’s a really easy way to get responsive (flexible) iFrame embeds with Bootstrap 3. Perfect for your Youtube and Vimeo embeds. Included classes are embed-responsive-4by3 and embed-responsive-16by9.

<div class="embed-responsive embed-responsive-16by9">
    <iframe class="embed-responsive-item" src="//www.youtube.com/embed/TcWPiHjIExA" allowfullscreen></iframe>
</div>

Demo

Filed under: Bootstrap
Back to posts