Kerry web design logo

How I Fixed the WordPress “Unexpected Response” Error When Uploading Large Videos to WordPress

We’ve all been there: you’ve spent hours editing a high-quality video, you go to upload it to your WordPress Media Library, and just as the progress bar hits the end… “Unexpected response from the server. The file may have been uploaded successfully.”

I recently ran into this exact issue while trying to upload a 150MB video to a site hosted on Hetzner and managed by SpinupWP. My PHP settings were already set to 256MB, and my memory limits seemed fine, yet the upload failed every single time.

After digging into the server architecture and logs, I realized that when you’re using a high-performance stack like SpinupWP + Nginx + Cloudflare, there are hidden “gatekeepers” that can kill your upload before it ever reaches WordPress.

Here is the exact solution that finally fixed the issue for me.


The Problem: The Hidden Gatekeepers

Even if your WordPress dashboard says you can upload 256MB, other layers of your tech stack might be blocking you:

  • Cloudflare: The Free and Pro plans have a hard 100MB limit.
  • Nginx: This web server software often defaults to a 64MB limit, which ignores your PHP settings.
  • PHP-FPM: While .user.ini is helpful, Nginx usually blocks the file before PHP can even process it.

The Step-by-Step Fix

Step 1: Disable the Cloudflare “Orange Cloud”

Before touching the server, this is non-negotiable for any file over 100MB. Because my file was 150MB, Cloudflare’s proxy was terminating the connection at the “edge”.

  1. Log into your Cloudflare Dashboard and go to DNS Settings.
  2. Find the A record for your domain.
  3. Click the Orange Cloud to turn it Grey (DNS Only).
  • Note: You can safely turn this back on once your upload is finished.

Step 2: Increase the Nginx client_max_body_size

Since SpinupWP uses Nginx, you have to manually tell the server to allow larger “bodies” (the technical term for your file upload).

  1. SSH into your Hetzner server as the site user or root.
  2. Navigate to the site’s Nginx subdirectory: SpinupWP uses a modular config system. Navigate here: cd /etc/nginx/sites-available/yourdomain.com/server/
  3. Create an override file: Using a separate file ensures SpinupWP doesn’t overwrite your changes during a future site update. sudo nano uploads.conf
  4. Add this line to the file: client_max_body_size 256M;
  5. Save and Exit: Press Ctrl+O, then Enter, then Ctrl+X.
  6. Test and Reload Nginx: This ensures your configuration is valid before applying it: sudo nginx -t (Wait for “syntax is ok”) sudo service nginx reload

The Result

After toggling Cloudflare to “Grey Cloud” and adding that one line to the Nginx config, the 150MB video uploaded perfectly on the first try.

If you are running a similar “LEMP” stack, remember that WordPress settings are only half the battle. You have to make sure the server software (Nginx) and your DNS provider (Cloudflare) are also configured to handle the heavy lifting.

Related articles

Ready to transform your business?

Schedule a free consultation today.

a man giving a thumbs up

Design My Website are a web design company based in Kerry. The majority of our meetings are done via video call but we can travel within Munster.

Contact Us
  • 083 1985 855
  • tommy@designmywebsite.ie
  • Kilcummin, Killarney, Co Kerry, Ireland
© 2026 Design My Website