I get 404 status when fetching images, and the http still contains that image. Image shows up in a browser, but the 404 code breaks some applications.

calls to wp-content/uploads/ are redirected in .htaccess:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteRule (.*) /index.php?getfile=$1 [L]

Why do I get a 404 status if the image is in there and is served?

  • 1) What are you "getting" the image from, i.e., what user agent, what computer, etc.? 2) What plugins are active? Do you have a hotlinking protection plugin in place?
    – ZaMoose
    Oct 13, 2010 at 14:43
  • I'm getting it with a flash application (crossdomain settings ok) and with a simple wget command. Also firefox shows image, but firebug console states it's a 404 response. It's nice of him to load it anyway. And I have no such plugni in place, and site is set to be visible to search agents.
    – naugtur
    Oct 14, 2010 at 7:50

2 Answers 2


Problem solved.

The plugin "User Access Manager" was found guilty of inserting a .htaccess file into wp-content/uploads/ and not handling calls properly afterwards.

I don't know how UAM plugin could be fixed, but It's ok to remove the .htaccess file. Nothing else depends on it. (at least in my case)

  • 1
    11 years later, same issue, same plugin Dec 8, 2021 at 23:04
  • Yes, found a .htaccess file inside wp-content/uploads/ even when I don't have the UAM plugin. Fixed after deleting the .htaccess file there. May 10 at 15:40

Log in to your WordPress root directory and rename .htaccess to something like .htaccess_old. Next, login to your WordPress admin area and navigate to Settings -> Permalinks Next, choose a different permalinks structure from what you currently have and click the Save Changes button. Next, select the original permalinks structure you had and click the Save Changes button once more. Note, this will create a new .htacess file in your server. Fixes the images returning the 404 error. Cheers!

Not the answer you're looking for? Browse other questions tagged or ask your own question.