DEV Community

Cover image for How do you embed a video from YouTube on your website?

How do you embed a video from YouTube on your website?

asghar_paracha profile image Asghar Paracha ・1 min read

Web video has become one of the most common ways for content sharing, tutorials, data, music, entertainment, and much more. For knowledge or entertainment, many people prefer to watch videos rather than read them.

Certainly, the first thing that comes to mind when you think about the subject is YouTube, the Internet's most popular video sharing site.

How to embed videos from YouTube on WordPress?

The mechanism is quite basic.

step 1. On YouTube, enter the URL of the film.

step 2. Copy the URL (click Right > Copy or CTRL + C / CMD + C)

step 3. Go to an entry or page where you want to show the video. Only right-click> Paste in the WordPress Editor.

When publishing or previewing it... Right there, the video will appear! (It's magic-like: P)

If you need to alter the video's properties, you can insert the code 'Embed' and adjust the dimensions and other properties.

Again, enter the video and click on the "Share" tab.

Copy the code that appears there after you have copied and changed the necessary one.

In the HTML (Text) section of the editor, paste the same code into the post so that the video will appear successfully.

As you can see, it is a very easy and quick process to insert YouTube videos into WordPress.

Have you got any other questions?

Discussion (0)

Editor guide