Detach An Image From A Post Or Page In WordPress

If you click on the "Add Media" button while adding or editing a page or a post, that piece of media gets attached to that post or page. This usually means it will show up in galleries, slideshows, etc. for that page or post. Up until recently, the only way to detach that media was to either delete it or install a plugin to do the job for you. With the release of WordPress 4.2, they have finally added this feature in, although a little hard to find if you don't know where you're looking.

WordPress 4.2 And Up

  1. Click on Media from the WordPress Admin menu.
  2. Switch the view to Media List.
     Media List View
  3. Find the media you would like to detach from a post or page within the list.
  4. Verify under the "Uploaded to" column that the media is attached to the post or page.
  5. Directly below the name of the post or page it should say "Detach".
  6. Click on "Detach".

That's it... that's all!

Before WordPress 4.2

Before the feature was finally added into WordPress, the same could still be done but it required a plugin. Here's a few plugins just in case anyone is running an old version... which you shouldn't be. Security vulnerabilities and such. You know, the internet.

Posted on: October 9, 2015

9 Responses

  1. I deleted a featured image and unfortunately also deleted from the media library. I had not “detached” the image and now it looks like the tag for that image is stuck on the website where the image used to be. Any idea how to get rid of it?

    • Not sure I’ve ran into that before. If you want to use the contact form and send me a message with specifics I could see if I could help.

  2. Kim

    Does detaching media make the page load faster?

    • Technically, the answer would be yes. The less a page or post has to pull the faster it would load. If the media isn’t actually displaying on the page and is only attached in the background, the load time difference shouldn’t be a huge deal. If the media is set to display on the page as well, then it would obviously jump a bit.

  3. Why would anyone want to detach, or even attach, images to a post? What’s the difference between the two?

    • When you upload an image through the media button in the page or post editor page it is automatically attached to that post or page. This gives it the capability to create galleries based on attached images for example. You would want to detach if you would like to keep the media but no longer have it associated with a specific post or page. Hope this helps clean things up!

      • Thanks! Sorry for the late reply.

  4. Excellent blog! Do you have any recommendations for aspiring writers? I’m hoping to start my own blog soon but I’m a little lost on everything. Would you advise starting with a free platform like WordPress or go for a paid option? There are so many options out there that I’m completely overwhelmed .. Any suggestions? Kudos!

    • I think something like WordPress would be a perfect place to start. You could either purchase the hosting and domain from someone like Varial Hosting and then install WordPress or you could use the WordPress website which requires a lot less setup. Using your own hosting and domain will give you a lot more control, but if you are unfamiliar with the technical side of things and would rather just write, the WordPress website hosted blog may be what you are looking for.

Leave a comment