I am getting 401 unauthorized error . My web service is written in mvc . in IIS configured to use windows authentication. Below is screen shot of fiddler
When I hit URL from browser it gives me popup window to enter user name and password. How can I avoid popup window?
I am calling this web api from another window service.
I suspect that the two web services may be hosted on the same server. In this case, the problem may be caused by the loopback check. In order to test, try referencing the service without using the fully qualified domain name and see if it works. If it does, use the following steps to specify which host names are on the local computer.
Method 1: Specify host names (Preferred method if NTLM authentication is desired) (https://support.microsoft.com/en-us/help/926642/)
To specify the host names that are mapped to the loopback address and can connect to Web sites on your computer, follow these steps:
**Edited to be in the form of an answer and include detailed steps from referenced links