Select Page

Video from sites such as YouTube and Vimeo can easily be embedded into a WordPress Post or Page. This is done using a protocol/format called oEmbed which avoids your having to copy-paste HTML from the site hosting the video you want to embed.

Embedding a video is very simple

  1. Obtain the video’s URL and copy it to your computer’s clipboard.
  2. In the Post or Page, paste the URL onto its own line.
  3. Make sure the URL doesn’t get turned into a live hyperlink.
  4. Save.

A YouTube video URL looks something like this:

…and a Vimeo URL looks like this:

When the Post or Page is viewed, WordPress will automatically display the video itself. The size of the video displayed may be dependent upon the host service and/or the HTML and CSS applied to the Post or Page, and some experimentation may be necessary.

For more control with YouTube videos, use YouTube’s Embed Code

Another way to embed a YouTube video on your site is by using YouTube’s Embed Code. This allows you to determine a size in pixels, and to turn off the “Related Videos” which YouTube will otherwise display at the end. To do this, go to YouTube and load the video’s own main page, the page you reach by pasting the URL into a browser’s address bar. Look below the video itself, and find 3 tabs — About, Share, and Add To. Click on Share. On the Share tab, click Embed. A box with some HTML code is shown. Below it, choose a size, and uncheck the option “Show suggested videos when the video finishes”. Then carefully copy the HTML code, paste it into your WordPress post or page, and Save.

Video and more can be embedded from these sites

Although video is the most common, other types of content can be embedded as well. Just paste a URL from any on this list of oEmbed-supported host sites: Instagram Scribd Viddler
Bunkr Qik SlideShare Vimeo
DailyMotion Photobucket SmugMug YouTube
Flickr PollDaddy SoundCloud
FunnyOrDie Rdio Spotify
Hulu Revision3 Twitter

Embedding vs. uploading and attaching

Embedding media as we discuss just above is, of course, different from uploading a media file.

The embedded file never takes up residence on the server where your WordPress websites is hosted; instead, it continues to live on the host site – YouTube, Vimeo, etc., and is served from that location.

A file which is uploaded is actually stored on your own server and served from there. This is the way typical image files are handled, but other file types can be handled this way as well.

Embedding is usually preferable for video files, which can be very large in megabytes. With other media, it makes more sense to upload.

Uploading and attaching file types other than images

WordPress allows you to upload and insert file types other than images, for example, PDFs or documents created with a word processor, spreadsheet or presentation program.

The process is very similar to uploading an image. The result is different in that the file is not displayed directly on the Post or Page; instead, a link to the file is placed on the Post or Page. On the live website, clicking that link opens the file in whatever way is determined by the user’s computer.

Here are the steps for uploading and attaching a PDF (or other file) to a Post or Page

  1. On the Edit Post or Edit Page screen, place the cursor where you would like the PDF link to appear.
  2. Click the Add Media button, just as you do when inserting an image.
  3. Click Upload and browse to the file and select it
  4. Fill in the Attachment Details, including a Title, which WordPress will use as the text which is linked.
  5. Under Link To, choose Media File.
  6. Click the button Insert Into Page.

The files you’ve uploaded are all viewable in the Media Library, and are by default are stored on your host server in the wp-content/uploads folder. They’re organized by year and month if that default setting is kept, under Settings > Media (which is highly recommended).