How to Attach a Word (or any) File to a Post

I saw a question recently asking how to attach a Word or .PDF file to a WordPress blog post.

Here’s the response I offered:

There are 3 ways you can do this…


If you only want the file to be available from 1 post – i.e. the post you are writing:

In this case place the cursor in the location where you want the link to your Word or PDF document to appear and click the ‘Add Media’ button.

This is the right-most button above the tool bar in the Visual view of your new-post-write screen.

The default screen that you’re presented with is ‘From Computer’. On this screen click the ‘Select Files’ button.

Browse to the location of the file on your PC, select the file and click ‘Open’ (or just double click the file).

In the following screen click ‘Insert into post’

That’s it.


If you want to make the file available from this post and any post in the future:

In this case create a folder on your server and upload your file to that folder

When you want to insert the file into this, or any future, posts click the ‘Add Media’ button but this time select the ‘From URL’ tab.

In the first line type in the full url of the location where you uploaded your file – e.g.  (or .pdf if it was a PDF file, .jpg if it was a JPEG, and so on).

You’ll need to make sure that both the spelling and the capitalisation are accurate otherwise the file will not be found.  To be sure, I usually copy the entire file name from Windows Explorer (or whatever you use) and paste it into the last part of the URL.

In the second line type in the link text – e.g. ‘Great article on uploading files’, or whatever you want.

Click ‘Insert into post’ and you’re done.


(And this is the one I usually use), simply type the link text into your post (or find the piece of text you want to make clickable), highlight it and click the ‘Insert Link’ button in your toolbar.

In the first line of the little window that comes up, type in the complete URL of the file you uploaded (as per the example above).

In the next line select whether you want the file to be opened in the same screen or a new screen.

(And this is the reason I prefer this method – I like to open attachments in a new screen so that readers don’t lose their place on the page they were reading).

In the next line give it a title.

Click ‘Insert’ and you’re done.

Pretty straightforward, but if you have any questions drop me a line via a comment below or through the Contact page.

What do you think?

Comments on this entry are closed.

  • zaiim Apr 23, 2009 @ 17:50

    isnt there an ftp addon so that you can upload files easily??
    sometimes i feel wordpress is really limited :S
    thx for the info anyways

    • WealthyDragon Apr 25, 2009 @ 9:41

      I don’t believe there is, other than the methods I described above.

      When you use the ‘Choose Files on Your PC’ option WordPress uploads the files to the Upload Directory in the Content folder. That’s the only FTP functionality I know about.



  • John Anderson May 21, 2009 @ 9:59

    Hi Martin,

    I am having trouble getting a PDF to attach to my blog.

    I have tried dozens of time, and each time when I return to the site to view it the words of the document appear, but not as a link. They are just in text, so I can’t actually open the PDF from the blog.

    Any tips would be great.



    • WealthyDragon May 21, 2009 @ 11:41

      John, hi,

      If you follow the steps above you should be able to attach a PDF without problems. Alternatively you could select the ‘From Computer’ tab in the media upload screen and select the preset ‘File URL’ at the bottom.

      This will cause WordPress to upload the file from your PC and store it in WordPress’ default file location.

      Clicking the ‘Insert Media’ link at the bottom will create the link.



  • Udegbunam Chukwudi Jan 1, 2010 @ 6:44

    Is there any Windows Live Writer plug-in that does this? I kinda prefer writing posts with WLW 2009.
    .-= Udegbunam Chukwudi´s last blog ..Apologies and Comments Policy Reviewed (Again)! =-.

    • Martin Jan 1, 2010 @ 13:24

      I honestly don’t know – I tried WLW a while ago but never took to it and haven’t looked at it since.

      Anyone else know if there’s a plugin for WLW?