What is apache's maximum url length?

What is the maximum length of a URL in apache? Where is it documented, and is it configurable?

I'm implementing an openid identity provider, and would like to know the limitations I'm up against. I know about the 2048 byte path limit on Internet Explorer. That can be handled specially using user agent detection. Other browsers have much higher URL limits.

So what I'm interested in is apache server limits when coding an application.


Solution 1:

The default limit for the length of the request line is 8190 bytes (see LimitRequestLine directive). And if we subtract three bytes for the request method (i.e. GET), eight bytes for the version information (i.e. HTTP/1.0/HTTP/1.1) and two bytes for the separating space, we end up with 8177 bytes for the URI path plus query.

Solution 2:

  • Internet Explorer: 2,083 characters, with no more than 2,048 characters in the path portion of the URL
  • Firefox: 65,536 characters show up, but longer URLs do still work even up past 100,000
  • Safari: > 80,000 characters
  • Opera: > 190,000 characters
  • IIS: 16,384 characters, but is configurable
  • Apache: 4,000 characters

From: http://www.danrigsby.com/blog/index.php/2008/06/17/rest-and-max-url-size/