It’s dead easy to add in a modal on a Bootstrap modal, but if you close the modal you’d expect the video to stop too, but, it doesn’t.

So you can stop this by forcing the iframe inside the modal to refresh when you trigger the close of the modal (close button or click away from the modal content)

So, by adding this script to your javascript, when the Bootstrap modal is closed the video inside the iframe of the modal will refresh and stop playing.

$('**modal class goes here**').on('hidden.bs.modal', function () {
    $('*modal class goes here** .embed-responsive').html('');
});

Bearing in mind the modal has an iframe video, that is wrapped in theĀ .embed-responsive class