Run a site using the IIS Express in command line

Useful when we are writing tests and working with Selenium, and we want to inspect some element on page with DevTools.

Open a command prompt and run the following command with appropriate paths:

"C:\Program Files (x86)\IIS Express\iisexpress.exe" /path:D:\Repos\Examples\TestAutomation\mvcforum\MVCForum.Website /port:9777

This command runs the app on http://localhost:9777

Leave a comment