Blog Post

IIS Support Blog
1 MIN READ

Enabling “Transfer-encoding: chunked” in the response header with IIS

Enamul_Khaleque's avatar
Nov 16, 2018
First published on MSDN on Mar 26, 2018
While assisting a customer on configuring ARR (Application Request Routing), we found that chunked transfer encoding was not working properly. After bit of workaround, we were able to fix it up. Here is a summary of the troubleshooting session.

Quick Note: "Chunked" is a type of transfer encoding by which the message body is transmitted to the client as chunks that are stamped with the size of the chunks (see section 14.40 of RFC 2068). With chunked transfer encoding, the client can make sure that it has received all of the data that the server sends. Chunked transfer encoding is similar to MIME encoding in relation to Internet mail (see RFC 822). The specific differences between MIME encoding and chunked transfer encoding are discussed in section 19.4 of RFC 2068.

To enable chunked transfer encoding, set the value for AspEnableChunkedEncoding to True for the site, the server, or the virtual directory that you want to enable chunked transfer encoding for:

  • Open a command prompt.

  • Change to the Inetpub\Adminscripts folder.

  • Run the following:
    cscript adsutil.vbs set /W3SVC/AspEnableChunkedEncoding "TRUE"

Updated Nov 16, 2018
Version 2.0

1 Comment

  • sanjeev695's avatar
    sanjeev695
    Copper Contributor

    I am using IIS 10.5 on a Windows 2019 datacentre edition. Enabling Scripts in the Features did not give the adsutil.vbs option, so i tried appCmd. However, this still did not enable the chunked Encoding.

     

    appcmd set config -section:system.webServer/asp /enableChunkedEncoding:TRUE

    Has anything changed in ISS 10.5? What should I be doing to enable this?

     

    I have also enabled compression for both static and dynamic content.