Title: HTTPS Image Upload Errors
Last modified: August 9, 2018

---

# HTTPS Image Upload Errors

 *  Resolved [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/https-image-upload-errors/)
 * After recently upgrading a bunch of sites to HTTPS it appears that uploading 
   images isn’t always working. Some images are uploading okay, but others aren’t.
   Very odd.
 * Anyway, all sites are at: WordPress 4.9.8, Wordfence 7.1.10, on HostGator, all
   but one site are using Really Simple SSL 3.0.5, and all also have .htaccess SSL
   redirects as well.
 * Files that do NOT upload properly when Wordfence is ENABLED do upload after Wordfence
   is DISABLED, so we think we’ve narrowed it down to that…although it could be 
   something else.
 * Also, it appears that the problem files do PARTIALLY upload, because an incomplete
   icon is created in the Media Library for the icon. When clicking on the icon 
   the uploaded image is visible and it can be set as a “Featured Image” for a Page,
   but he image icon in the Library is NEVER complete even after refreshing the 
   page. It’s almost as if not all of the WordPress image sizes are being created
   or something when the initial upload is attempted.
 * Anyway… very odd and as noted, it only started happening after switching to HTTPS.
   Any ideas or suggestions? Thanks!
 * PS – the upload errors happen when images are dragged and dropped or when using
   button.

Viewing 10 replies - 1 through 10 (of 10 total)

 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10576414)
 * Side note… the following error message was in the logs multiple times, probably
   for each image upload attempt:
 * [09-Aug-2018 19:10:59 UTC] PHP Fatal error: Maximum execution time of 30 seconds
   exceeded in /home1/<directory info removed>/wp-includes/class-wp-image-editor-
   imagick.php on line 362
 * Also another odd thing noticed… a 10Mb file uploads fine each time, yet a 1.1Mb
   file doesn’t. Maybe the smaller one is timing out because it’s a complete color
   image and the larger one has a transparent background…just BIG in size.
 *  [wfalaa](https://wordpress.org/support/users/wfalaa/)
 * (@wfalaa)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10596210)
 * Hi [@millionairesn](https://wordpress.org/support/users/millionairesn/)
 * I wonder what happens when you switch the firewall mode into “[Learning Mode](https://www.wordfence.com/help/firewall/learning-mode/)“?
   Also, can you narrow down this issue to a certain image extension?
 * Thanks.
 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10597883)
 * Hey wfalaa… thanks for responding.
 * We switched the firewall mode to “Learning Mode” and the same image that was 
   having problems when it was uploaded before, still didn’t completely upload. 
   The following message was in the error.log file:
 * [16-Aug-2018 20:59:03 UTC] PHP Fatal error: Maximum execution time of 30 seconds
   exceeded in /home1/<<directory path removed>>/wp-includes/class-wp-image-editor-
   imagick.php on line 362
 * Not sure WHY the server is now timing out when Wordfence is active…? The site
   is on HostGator, always has been, and we’ve never had issues like this before.
   But that was before migrating to their FREE SSL solution. Although as previously
   noted, when we DEACTIVATE Wordfence the file does upload…odd?
 * As for image extension… the 10+ Mb image that uploaded fine was a .PNG, single
   color with transparent background. The images that are NOT uploading are smaller.
   JPG files, just over 1 MB, but with lots of colors and FULL backgrounds.
 * NOTE: we just converted the .JPG image to a .PNG file, it’s size is now 2.6 MB(
   just over twice the size of the original file) and guess what… it uploaded fine.
   UGH!
 * So… maybe it is a file TYPE problem…?
 * Hopefully that helps identify a fix. Switching images to a different type is 
   doable, but just not preferred since the file sizes jump too much.
 * Thanks for helping to narrow this down. Let us know if you think there is a fix,
   so we can get the .JPG files to upload too.
 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10597888)
 * NOTE… switched the Firewall setting back to “Enable and Protecting” and the larger.
   PNG file once again loaded successfully. So it does look like it has something
   to do with the .JPG extension.
 *  [wfalaa](https://wordpress.org/support/users/wfalaa/)
 * (@wfalaa)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10628461)
 * Hi [@millionairesn](https://wordpress.org/support/users/millionairesn/)
 * May I know if this happens with different .jpg images? or just a specific one?
   it could be something related to the image filename? try to rename this file 
   into something else.
 * Thanks.
 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10630633)
 * It’s happened to the original file, as is, and even after renaming it to something
   else. It also happens with other .jpg files too.
 * However, when any original file is converted to a .png (which is usually twice
   the size of the .jpg) the converted files ALL seem to upload just fine.
 * So it definitely seems to be something with the .jpg file extension.
 * Odd to say the least. Thanks for your help and let us know if there is anything
   we should try.
 *  [wfalaa](https://wordpress.org/support/users/wfalaa/)
 * (@wfalaa)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10643496)
 * Hi [@millionairesn](https://wordpress.org/support/users/millionairesn/)
 * Please send us one of those “.jpg” images that caused this timeout issue to “
   samples [at] wordfence [dot] com” and make sure to mention that this file is 
   not malicious but causes a timeout while uploading and paste a link to this forum
   thread. Our team wants to take a look at this file.
 * Meanwhile, you can try disabling “file_upload Malicious File Upload (Patterns)”
   firewall rule from (Wordfence > Firewall > Firewall Options > Advanced Firewall
   Options > Rules) then recheck this issue.
 * Thanks.
 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10670255)
 * Sorry for the delay in responding, holiday week and back to school had us busy.
   We tried to DISABLE the suggested setting you provided above and that did NOT
   change anything, we still could NOT upload the .JPG files.
 * Two emails were sent to the address listed above. The first include 4 files that
   were quick screen captures that related to the error were seeing and then we 
   attached one of our problem files. Unfortunately not the one we referenced in
   the error messages or the site, so that’s why we sent a second email with the
   image that was referenced.
 * Either way, both images are .JPG and won’t upload when Wordfence is active. As
   noted in the email, let us know if anything else is needed. Thanks!
 *  [judylmohr](https://wordpress.org/support/users/judylmohr/)
 * (@judylmohr)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10931653)
 * I’m experiencing the exact same issue. I thought I was going insane. If it really
   is WordFence that is causing my issues, guess what… WordFence is disappearing
   off my sites. It’s already had to be removed from one site because of the conflicts
   it caused with the ChatWing chat room that the site in question used.
 * Thanks @millionaireson for this. I’m running the exact same configuration as 
   you (also on Hostgator), so it is comforting to know that I’m not the only one
   with this problem.
 * UPDATE: I have just deactivated WordFence, just to see if this is actually the
   source of my issues… The image that I’ve been fighting with all morning uploaded
   first try. I will continue to run with “deactivated WordFence”, just to test 
   if any further issues arise. If this deactivation solves my problems, I will 
   be deleting the plugin and looking for an alternative. I can’t have a plugin 
   installed that’s going to have erratic behavior and give me nightmares when I’m
   just wanting to write a quick blog post.
 *  Thread Starter [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * (@millionairesn)
 * [7 years, 5 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10936160)
 * Hey Judy… we have no idea what happened, but all is working fine again. Since
   we first opened this topic we have updated many plugins, including WordFence,
   and we’ve also moved our site to a newer HostGator account…ugh…the new account
   has it’s own issues, but that’s another long story.
 * Anyway, all is working fine now and like so many other software issues we’ve 
   seen over the years, we have no idea what fixed it. At least for now WordFence
   and everything else, file uploads included, are all working fine.
 * We’ll cross our fingers that yours fixes itself too.

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘HTTPS Image Upload Errors’ is closed to new replies.

 * ![](https://ps.w.org/wordfence/assets/icon.svg?rev=2070865)
 * [Wordfence Security - Firewall, Malware Scan, and Login Security](https://wordpress.org/plugins/wordfence/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordfence/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordfence/)
 * [Active Topics](https://wordpress.org/support/plugin/wordfence/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordfence/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordfence/reviews/)

## Tags

 * [image uploading error](https://wordpress.org/support/topic-tag/image-uploading-error/)
 * [media library](https://wordpress.org/support/topic-tag/media-library/)

 * 10 replies
 * 3 participants
 * Last reply from: [Millionairesn](https://wordpress.org/support/users/millionairesn/)
 * Last activity: [7 years, 5 months ago](https://wordpress.org/support/topic/https-image-upload-errors/#post-10936160)
 * Status: resolved