I just finished adding C# Web API components (Web API Models & Controllers) to a localhost
copy of an existing project.
This Web API\'s GET-methods shou
In visual studio 2015 with IIS express: first in project properties change project url from http://localhost:(Port No) to : http://127.0.0.1:(Port No)
and click on Create Visual Directory
then go to your solution path and open ".vs" dirctory (directory is hidden) and open "applicationhost.config"
<sites>
<site name="WebSite1" id="1" serverAutoStart="true">
<application path="/">
<virtualDirectory path="/" physicalPath="%IIS_SITES_HOME%\WebSite1" />
</application>
<bindings>
<binding protocol="http" bindingInformation=":8080:localhost" />
</bindings>
</site>
<site name="####" id="2">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="E:\Visual Studio 2015\Projects\####\####" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:5050:localhost" />
</bindings>
</site>
<site name="####(1)" id="3">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="E:\Visual Studio 2015\Projects\####\####" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:5050:127.0.0.1" />
</bindings>
</site>
<siteDefaults>
<logFile logFormat="W3C" directory="%IIS_USER_HOME%\Logs" />
<traceFailedRequestsLogging directory="%IIS_USER_HOME%\TraceLogFiles" enabled="true" maxLogFileSizeKB="1024" />
</siteDefaults>
<applicationDefaults applicationPool="Clr4IntegratedAppPool" />
<virtualDirectoryDefaults allowSubDirConfig="true" />
</sites>
and change last binding section of your web app from *:(Port No):localhost to *:(Port No):127.0.0.1
and stop all running project on IIS Express and restart them.