Apparently Nginx now supports Chunked, but I receive error "411 Length Required" when a tablet device sends a Chunked request to Nginx. Any advice as to how to configure Nginx to support Chunked? I'm using v.1.3.9.

I know a similar question was asked, but it was in 2010 before chunked was supported in Nginx.

My nginx.conf:

master_process off;
worker_processes  1;
daemon off;

pid        /usr/nginx/logs/nginx.pid;

events {
    worker_connections  1024;

http {
    ngao_filters_directory /usr/nginx/filters;

    include       mime.types;
    default_type  application/octet-stream;

    # prevent caching by client
    add_header    Cache-Control "no-store, no-cache";

    sendfile        on;
    keepalive_timeout  65; 

  server {
        listen       8081;
        server_name  localhost;
    client_max_body_size 3m;
    chunked_transfer_encoding on;

    scgi_temp_path  /usr/nginx/scgi_temp;
    uwsgi_temp_path /usr/nginx/uwsgi_temp;

        location / {
        proxy_buffering off;

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   html;
        } } }
  • Probably a dupe serverfault.com/questions/159313/…
    – Danack
    May 12, 2013 at 16:03
  • 5
    No, this is not a dupe. This question deals with chunked requests while the other deals with chunked responses. May 12, 2013 at 22:00
  • 1
    Ah not a dupe at all. According to this ruby-forum.com/topic/4408411 no configuration is required 'There are no special directives at all. It just works.'. If it's not working from a tablet, how about testing with CURL 'curl -v -X POST --header "Transfer-Encoding: chunked" -d @Test.txt "localhost:8080"' ?
    – Danack
    May 13, 2013 at 22:17

1 Answer 1


(Posting a response because I cannot comment yet. Need >50 reputation)

You should read this.

The trick is to set proxy_buffering off; in your location block.

^--- I see you have already tried this.

Nginx does not currently support chunked POST requests [...]
The only working solution I found is this:

^--- But I think this is your best bet. It implies that you need to compile nginx, though

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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