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
- Click on Media from the WordPress Admin menu.
- Switch the view to Media List.
- Find the media you would like to detach from a post or page within the list.
- Verify under the "Uploaded to" column that the media is attached to the post or page.
- Directly below the name of the post or page it should say "Detach".
- 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.