Title: Attach Unattached Images
Author: Rachid Aitouaissi
Published: <strong>June 18, 2026</strong>
Last modified: June 18, 2026

---

Search plugins

![](https://s.w.org/plugins/geopattern-icon/attach-unattached-images.svg)

# Attach Unattached Images

 By [Rachid Aitouaissi](https://profiles.wordpress.org/rachidaitouaissi/)

[Download](https://downloads.wordpress.org/plugin/attach-unattached-images.1.0.zip)

 * [Details](https://wordpress.org/plugins/attach-unattached-images/#description)
 * [Reviews](https://wordpress.org/plugins/attach-unattached-images/#reviews)
 *  [Installation](https://wordpress.org/plugins/attach-unattached-images/#installation)
 * [Development](https://wordpress.org/plugins/attach-unattached-images/#developers)

 [Support](https://wordpress.org/support/plugin/attach-unattached-images/)

## Description

Every time you upload an image in WordPress, it gets stored in the media library
as an “unattached” file — meaning it has no parent post assigned. Over time this
leads to a cluttered media library and orphaned attachment pages that hurt your 
SEO.

Attach Unattached Images scans your content and automatically links each image back
to the post, product, or download it belongs to.

#### Supported Post Types

The plugin scans the following post types:

 * **Post** — the default WordPress blog post type.
 * **Product** — the primary post type used by WooCommerce.
 * **Download** — the primary post type used by Easy Digital Downloads (EDD).

#### What Gets Scanned

For each post, the plugin can scan:

 * **Post Content** — the main body of the post.
 * **Post Excerpt** — the summary/excerpt field.
 * Or **both** — configurable from the plugin settings.

The plugin uses batch processing so there is no post limit and no PHP timeout risk,
even on large sites with thousands of posts.

#### Attachment Page Redirector

Every image uploaded in WordPress gets its own attachment page. These pages are 
usually empty and thin on content — bad for SEO and confusing for visitors.

Enable this option to silently redirect anyone who lands on an attachment page straight
to the parent post or product instead — keeping your bounce rate low and your content
front and centre.

The redirect uses a **301 (permanent)** status code, so search engines will update
their index and pass full SEO value to the parent post.

#### How to Configure

 1. Go to **Settings > Attach Unattached Images** in your WordPress admin.
 2. Select the post types you want to scan: Posts, Products, and/or Downloads.
 3. Choose whether to scan Post Content, Post Excerpt, or both.
 4. Optionally enable the **Attachment Page Redirector** to redirect attachment pages
    to their parent post.
 5. Click **Start Scan** — the plugin will process your content in batches automatically.

### Features

 * Scan posts, WooCommerce products, and EDD downloads for unattached images
 * Automatically attach unattached images to their correct parent post
 * Choose to scan post content, post excerpt, or both
 * Batch processing — no post limit, no PHP timeout issues
 * Redirect attachment pages to the parent post or product with a 301 redirect
 * Lightweight and easy to configure

## Installation

 1. Upload the plugin files to the `/wp-content/plugins/attach-unattached-images/` 
    directory, or install directly through the WordPress Plugins screen.
 2. Activate the plugin through the **Plugins** screen in WordPress.
 3. Go to **Settings > Attach Unattached Images** to open the plugin settings page.
 4. Select your post types and scan options.
 5. Click **Start Scan** to begin attaching images automatically.

## FAQ

### Which post types does the plugin support?

The plugin supports WordPress Posts, WooCommerce Products, and Easy Digital Downloads(
EDD) Downloads.

### Is there a limit on how many posts can be scanned?

No. The plugin uses batch processing to handle any number of posts without hitting
PHP memory or timeout limits.

### What content does the plugin scan to find images?

You can choose to scan the post content, the post excerpt, or both — configurable
from the settings page.

### What does the Attachment Page Redirector do?

It automatically redirects visitors who land on an attachment page to the parent
post or product using a 301 permanent redirect. This improves SEO by consolidating
page authority to the parent content and avoids thin/empty attachment pages being
indexed by search engines.

### Will the plugin affect images that are already attached?

No. The plugin only processes images that are currently unattached (i.e. have no
parent post assigned in the media library).

## Reviews

There are no reviews for this plugin.

## Contributors & Developers

“Attach Unattached Images” is open source software. The following people have contributed
to this plugin.

Contributors

 *   [ Rachid Aitouaissi ](https://profiles.wordpress.org/rachidaitouaissi/)

[Translate “Attach Unattached Images” into your language.](https://translate.wordpress.org/projects/wp-plugins/attach-unattached-images)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/attach-unattached-images/),
check out the [SVN repository](https://plugins.svn.wordpress.org/attach-unattached-images/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/attach-unattached-images/)
by [RSS](https://plugins.trac.wordpress.org/log/attach-unattached-images/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 1.0

 * Initial release
 * Automatic image attachment via batch scanning
 * Support for Posts, WooCommerce Products, and EDD Downloads
 * Scan post content, excerpt, or both
 * Attachment page 301 redirector

## Meta

 *  Version **1.0**
 *  Last updated **11 hours ago**
 *  Active installations **Fewer than 10**
 *  WordPress version ** 5.0 or higher **
 *  Tested up to **7.0**
 *  PHP version ** 7.2 or higher **
 * Tags
 * [attachments](https://wordpress.org/plugins/tags/attachments/)[images](https://wordpress.org/plugins/tags/images/)
   [media](https://wordpress.org/plugins/tags/media/)[seo](https://wordpress.org/plugins/tags/seo/)
 *  [Advanced View](https://wordpress.org/plugins/attach-unattached-images/advanced/)

## Ratings

No reviews have been submitted yet.

[Your review](https://wordpress.org/support/plugin/attach-unattached-images/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/attach-unattached-images/reviews/)

## Contributors

 *   [ Rachid Aitouaissi ](https://profiles.wordpress.org/rachidaitouaissi/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/attach-unattached-images/)