This tutorial shows how to embed video into HTML page.
How to embed video into HTML page
YouTube video
-
Open video on YouTube, right-click on video and select Get video URL. Copy this code.
-
Paste the code that you have copied in the previous step into desired location of .html file and save the changes you have made to .html file.
-
Refresh the page and check how your site looks.
Vimeo video
-
Open video in Vimeo. Click on share icon. You may click on Show options link in order to adjust the layout. Copy the code under Embed field.
-
Paste the code that you have copied in the previous step into desired location of .html file and save the changes you have made to .html file.
-
Refresh the page and check how your site looks.
WEB player
-
Now we are going to add video using a web player. We will add the code that you can check below. Code source src="video1.mp4"defines path to video file, type="video/mp4" defines type of file. You can find more information regarding video tag there.
<video width="320" height="240" controls> <source src="video1.mp4" type="video/mp4"> Your browser does not support the video tag. </video>
-
Paste the code that you have copied in the previous step into desired location of .html file and save changes you have made to .html file.
-
Refresh the page and check how your site looks.
Feel free to check the detailed video tutorial below: