WordPress bloggers always like to add some images, pictures, video, mp3, audios, and other formatted content into a blog post, which make the post diverse and splendid. However, as we introduced before, you should not upload a video to WordPress directly. So you have to embed a video if you want to integrate it into WordPress posts. In this tutorial, we just introduce the method carefully to embed a YouTube video in WordPress blogs. With the detailed guidelines, most webmasters even the novices can successfully complete the process with ease.
Since WordPress 3.6, the software has been released a new feature, offering the ability to upload video directly or embed a third party video into a post or page content. Generally, we recommend host video on a video sharing website like YouTube since its servers are optimized for streaming video. Besides, it also saves the cost of your disk space and bandwidth.
Usually, there are two common ways to embed YouTube videos. In the following, we introduce them separately.
Using a URL
Adding YouTube video with a URL is quite easy. You can just follow the below steps and paste the video link.
- Log into WordPress Dashboard and create a new post or page at first.
- Write your content, and just enter the video URL link on a single line and keep it not hyperlinked. Just like the following:
- Then, WordPress will read its extension and automatically display the media player, playing off of a different server as the following.
Instead of using a URL, some webmasters also like to add video manually. In this case, they can use shortcodes to insert a video by hand. Besides, they can also define the width and height of YouTube media player with shortcodes.
Just create and edit a new post, then copy and paste the following code into the content where you want to add the video on. Note that you should switch the content editor in Text mode, and replace the src value with video link you need to insert.
<iframe width="690" height="388" src="http://www.youtube.com/embed/xngJPd9Vk-s" frameborder="0" allowfullscreen="true"></iframe>
Then, you can see that YouTube player displays the video as the following: