[Solved] HTTP Error 400. The request hostname is invalid.

Error

when vs2017 develops a web project

It can be used by local localhost, and the service cannot be accessed through IP.

Solution: locate the applicationhost.config file in the. Vs/config folder of the project directory and open it

Add IP access

Restart done

Read More: