How To Embed Video In WordPress

How To Embed Video In WordPress

Up until now, we’ve focused mainly on embedding videos from external sources, like YouTube or Vimeo. However, WordPress also lets you self-host videos on your own server and embed them that way. WordPress even includes its own basic video player.

However, there’s a caveat. In most situations, we do not recommend doing it this way. Self-hosting your own videos will eat up a lot of bandwidth and storage. Additionally, it’s hard to handle all the technical details such as video encoding and different resolutions. Sites like YouTube and Vimeo handle all this technical stuff for you, but you’ll be responsible for it if you try to self-host videos. Shawn at WP101 has a good post explaining why self-hosting videos is usually not a great solution.

However, there might be a situation in which you still find that self-hosting videos is your best bet.

First, you need to upload the video file to your WordPress Media Library (Media → Add New). Then, here’s how to embed it:

Block editor:

Add a new Video block and select the video file from your Media Library. In the Block sidebar, you’ll get some additional options for controlling how your video works:

CSS Cleaner is a brilliant free online tool to take care of your dirty markup.

Leave a Comment