DNS Redirector
 Return to FAQ List

FAQ 169: Length of the URL for this request error

Category: BlockedIP function

In some cases the Blocked site may display an error "The length of the URL for this request exceeds the configured maxUrlLength value"

This is because the default IIS setting of 260 is shorter than the URL being blocked.
Note that the content is blocked regardless, it's only the blocked site does not display properly in the end-user browser.


On your IIS server which hosts the blocked site, download: REG-UrlSegmentMaxLength.zip then open the .reg file.

In the root of the blocked site find the "web.config" file and edit using notepad
Modify the system.web section to include the two httpRuntime declarations as shown below...

Our suggestion for both the registry edit and the web.config file is to set the length at 500, however a value up to 2048 also works.

Also see...
UrlSegmentMaxLength registry setting
maxRequestPathLength setting does not work
maxUrlLength setting in web.config
IIS request limits

Related articles
FAQ 166  Not all sites are blocked correctly

DNS Redirector | Legal Information | 2003-2019