Beginner's Guide for WordPress / Start your WordPress Blog in minutes

How to Organize WordPress Files in Media Library Folders

Do you want to organize WordPress files in the media library folders?

By default, WordPress automatically creates folders for different years and months, and then adds each media file to the right folder based on its upload date. However, you might want to create your own file system, to better suit your website.

In this article, we’ll show you how to organize WordPress media files into custom folders.

Organizing your media library folders in WordPress

Why Organize Your Files in Media Library Folders?

Normally, WordPress stores all your images and other media files in a /wp-content/uploads/ folder. Inside this folder, WordPress creates sub-folders for the years and months. It then adds your files to different folders based on the date when you uploaded them.

For example, an image that you uploaded in January 2023 will be stored in the /wp-content/uploads/2023/01/ folder.

The WordPress default media library structure

This works well for most websites, but sometimes you may want to customize how WordPress stores media files.

For example, if you run a photography website then you might organize your images into topic, location, or event folders. Similarly, if you have a portfolio website then it may be easier to organize media uploads by type, client, or industry.

This can help you find the right file more easily, and may even improve image SEO by adding relevant keywords to your image file URLs.

Having said that, let’s take a look at how to easily create folders to organize your WordPress media files.

How to Organize Your WordPress Files in Media Library Folders

The easiest way to create custom media folders in WordPress is by using Media Library Folders. This free plugin allows you to create folders and move, delete, and rename files directly in the WordPress dashboard.

This is much easier than connecting to your server using an FTP client.

First, you need to install and activate the Media Library Folders plugin. For more details, see our step-by-step guide on how to install a WordPress plugin.

Upon activation, go to Media Library Folders in the WordPress dashboard. You’ll now see all the folders inside your WordPress upload directory.

Organizing files in the WordPress media library

From here, you can create new folders and add files to them. You can also move, copy, rename, or delete files on your WordPress website.

To create a new folder, simply click the ‘Add Folder’ icon, which looks like a small folder with an ‘+’ symbol on it.

Creating new folders in the WordPress media library

In the popup, type in a name for the folder. You can’t use spaces in folder names, so you’ll need to separate words using a hyphen or underscore. This name will be added to the image URL, so you may be able to improve your WordPress SEO by adding relevant keywords.

After that, click on the ‘Create Folder’ button.

Adding more folders to the WordPress media library

You can also create subfolders by selecting the parent folder towards the left of the screen.

Then, go ahead and click on the ‘Add Folder’ icon.

Creating subfolders in the WordPress media library

You can now give the subfolder a name and click on ‘Create Folder.’

To see all your subfolders, simply click on the small white arrow next to any parent folder.

Adding sub-folders in the WordPress media library

To add files, click to select the folder where you want to store these items. Then click on the ‘Upload Files’ icon, which has an upwards arrow.

You can now go ahead and upload as many files as you want.

How to organize files in the WordPress media library

After a few moments, you’ll see a preview of all the files and their filenames on your WordPress blog.

You can now add these images to your posts or pages just like any other files that you’ve uploaded to the media library.

How to organize files in the WordPress media library

Moving and Copying Your Files in Media Library Folders

Sometimes you may need to move an existing media file into a different folder. With this plugin, you can either move the original file or create a copy in the new location.

Moving an Image to a New Folder in the Media Library

To move an image or any other file, simply click on the ‘Move’ icon so that it turns blue. You’ll also see the following message: ‘Drag and drop is set for moving files.’

Moving files around the WordPress media library

Now, find the image that you want to move and drag it to the new location.

Just before you release the file, the destination folder should be highlighted in blue. When you see this highlight, drop the file to move it to the new location.

Moving images, videos, and other files around the media library

Copying an Image to a Different Folder in the Media Library

Sometimes, you may want to create a copy of a file in a new location. For example, if you manage a multi-author WordPress blog, then you may want to create your own version of another user’s image.

Since the original image remains in place, this can also help avoid confusing the image’s owner, which will improve the editorial workflow.

If you prefer to copy the image then make sure you click on the ‘Copy’ icon so that it turns blue. It will also show the message: ‘Drag and drop is set for copying files.’

Copying media files in the WordPress library

Now, find the image that you want to copy and drag it into the new destination folder. Just before releasing the file, make sure the folder is highlighted in blue.

Media Library Folders will now create a copy and add it to the new folder while keeping the original file in place.

Renaming Files and Folders in Media Library Folders

You can also change a file’s name using the Media Library Folders plugin. First, find the file that you want to change and click the checkbox below it. Next, click the ‘Rename a File’ button, which looks like a small pencil.

Renaming images and other files in the WordPress dashboard

In the popup, type in the filename that you want to use. An SEO-friendly name can help optimize your images, so we recommend using keywords wherever possible.

To save the new name, click on the ‘Rename’ file button.

How to rename image files in WordPress

Just be aware that you can’t rename or move folders inside the Media Library Folders plugin. Instead, you’ll need to use a workaround where you create a new folder in the desired location, move all your files into it, and then delete the original folder.

When you’re ready to delete the folder, right-click on it and then select ‘Delete this folder?’

Deleting images in the WordPress dashboard

You’ll now see a message asking if you really want to delete the folder. To go ahead and permanently remove it, simply click on ‘OK.’

Sometimes, you may see the message ‘This folder is not empty and could not be deleted’ even though the folder looks empty. This usually happens because WordPress automatically creates additional versions of your images, which you still need to delete.

To see these images, simply click on the ‘Sync folder contents’ button.

Syncing the folder contents in WordPress

After this, you should see all the duplicate images. Simply delete these copies following the same process described above, and then try deleting the folder again.

For more troubleshooting tips, see our guide on how to fix common image issues.

We hope this article helped you learn how to organize WordPress files in media library folders. You might also want to see our guide on how to create a custom Instagram photo feed in WordPress or see our expert pick of the best SEO plugins and tools that you should use.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Disclosure: Our content is reader-supported. This means if you click on some of our links, then we may earn a commission. See how WPBeginner is funded, why it matters, and how you can support us. Here's our editorial process.

The Ultimate WordPress Toolkit

Get FREE access to our toolkit - a collection of WordPress related products and resources that every professional should have!

Reader Interactions

6 CommentsLeave a Reply

  1. Hi, Thanks for the article, it’s something that bothered me since a long time without really realizing that it was a problem :)

    My only question: if using this plugin does it physically create those folders in the backend and move the images to the correct location? And if so, does it then automatically relink my website pages where those images are used?


    • I tried it, and No, it’s just on the frontend for easy access and order.
      Sorta like those “Folders” plugins that let you organize posts and other stuff.
      You can manually move the files in your CPANEL, but it causes broken image links on your site, so a plugin is the only usable option that I know of.

  2. Hi, the media folder access can be restricted by WordPress User or WordPress user role in the plugin WP Media Folder. Admin would still have access to all the media. This is pretty convenient for website with multiple editors :)

  3. is there a convenient way so that each user get access to a separate folder in the media gallery ?

    • We would recommend reaching out to the plugin’s support to see if that can be an option in the future.


Leave A Reply

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.