Solved

URL Max Character lengths?

Posted on 2011-02-11
3
351 Views
Last Modified: 2013-12-24
Hello, I need to create a URl which will contain a lot of querystrings therefore making a very long URL.

I've been reading various online resourceser/sites about character string lengths. My question is: what is the actual maximum character length that can be used nowards?
It seems to be browser specific. Where I find a complete list of briwser character length restrictions?

Thanks in advance!
0
Comment
Question by:speedygonzalez
  • 2
3 Comments
 
LVL 31

Accepted Solution

by:
Frosty555 earned 125 total points
ID: 34870391
The maximum length of a URL depends both on the browser (the HTTP Client), and also on the web server (the HTTP Server).

Some interesting info on it is here:
http://www.boutell.com/newfaq/misc/urllength.html

I'd limit yourself to about 2000 characters to be safe with all modern browsers.
0
 

Author Comment

by:speedygonzalez
ID: 34870490
Thanks Frosty. That's very helpful. Is that current also (I note the article was written in 2006)?

I read somewhere that HTML 4 will allow longer valus. Are we usig HTML 4 now or 5? I'm not too familiar on it to be honest.
0
 
LVL 31

Expert Comment

by:Frosty555
ID: 34890221
Hi speedygonzalez,

It is pretty likely that most modern browsers no longer have the limitations on the URL length imposed on them. The problem is more frequently you will find that web servers (such as IIS) can be several years old and have never been upgraded / patched depending on the server they are running on, which is something you can't really control.

Nevertheless the general practice of not allowing your url lengths to exceed about 2000 characters is still a good idea. If you are passing that much data you should probably be rethinking things and using cookies / sessions / POST instead.

It's not the HTML specification that puts limits on URL lengths, it's the HTTP specification (HTML is just the markup language for describing web pages, it doesn't have anything to do with the communication between server and client). The HTTP specification does not impose any actual limits on the URL lengths, technically it can be of unlimited length. The problem is purely an issue with specific browsers and webservers that have limitations due to their poor design - basically somebody at Microsoft cut corners somewhere, and now we all have to bend over backwards to support it ;)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
If you get continual lockouts after changing your Active Directory password, there are several possible reasons.  Two of the most common are using other devices to access your email and stored passwords in the credential manager of windows.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now