Nginx + WordPress : 414 Request-URI Too Long

Solution 1:

From somewhere on the internet:

Most likely you are trying to configure client_header_buffer_size/large_client_header_buffers in a pure virtual server{}. This won't work as request headers parsing happens before Host header is known (and virtual server isselected), hence parseing happens in a context of the default server for a listen socket.

You have to configure client_header_buffer_size/large_client_header_buffers in a default server (or at http level).

Solution 2:

Found the guilty one... Better WP Security Plugin !

There is an option to limit the URLs length.

However, this plugin is amazing but adds many tweaks to protect a Wordpress installation by default.

Thanks all for your help!