Tuesday, 15 November 2016

How to host WCF service in IIS manager

To host the WCF service, follow the below steps:
  1. Add virtual directory in "IIS Manager"
    1. PC Name -> Sites -> Default Web Site -> Add virtual directory
    2. Type in the alias (name) and browse to the physical path (where .svc file resides).
  2. Right click on the added application, select "Convert to application".
  3. Test the hosted application by clicking the "Browse button".

Possible issues:
  1. HTTP Error 404.3 - Not Found The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map.
Solution:
Turn on/off windows features: Make sure that the below features are turned on:
  • .net framework 3.5 and 4.5.
  • IIS


  1. If you can't access WCF service hosted on IIS remotely but can access it locally
Solution: 
Make sure firewall on the hosted machine is OFF.

No comments:

Post a Comment