IIS hosted wcf returns me blank page

I have a wcf application. It has "Service1.svc" file. In the web.config file I specified


as an endpoint. When clicking browse from Visual Studio there is no problem. But, when I hosted it on IIS server I get a blank page. The interesting thing is, If I remove the address from the web. config this time I can see the service at this address.


web.config file is as below:

    <?xml version="1.0"?>
        <behavior name="EmployeeServiceBehaviour">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="true" />
      <service behaviorConfiguration="EmployeeServiceBehaviour" name="EmployeeConfiguration">
        <endpoint address="http://localhost:2005/EmployeeService.svc" binding="basicHttpBinding"
          bindingConfiguration="" contract="IEmployeeConfiguration" />
    <compilation debug="true"/>
    <directoryBrowse enabled="true"/>

Could you please explain, why I get a blank page on IIS when I provide the adress.

I think you can remove all text on the address before Service.svc. This might be an issue with different urls.

When you specify the address part, you tell WCF the service is only available on that address. When going through the endpoints, WCF will not find one that matches the given URL and bail out.

When you have multiple endpoints you need the address field. Otherwise you don't.

Read http://msdn.microsoft.com/en-us/library/ms733749(v=vs.110).aspx

And in particular this part:

When hosting with IIS, you do not manage the ServiceHost instance yourself. The base address is always the address specified in the .svc file for the service when hosting in IIS. So you must use relative endpoint addresses for IIS-hosted service endpoints. Supplying a fully-qualified endpoint address can lead to errors in the deployment of the service.

Blank Page while accessing a WCF Service hosted in IIS., Could anyone please tell me why I am getting blank page on one Server 2008 & XP and why bad request on Vista?How can I correct it? When hosting with IIS, you do not manage the ServiceHost instance yourself. The base address is always the address specified in the .svc file for the service when hosting in IIS. So you must use relative endpoint addresses for IIS-hosted service endpoints.

This may happen in HTTP Activation is not installed in Programs and Features in your Windows installation. Check HTTP Activation for both .Net 3.5 and 4.6 to enable opening WCF service via HTTP request to .svc file hosted in IIS.

Local IIS Hosted WCF return Blank Page, I have created a simple WCF Service application. Now I hosted it on Local IIS, But when I run it, It shows a Blank page. My WCF Serice Code as  IIS 7 seems to follow this approach - I haven’t been able to find a helpful log message for any of my blank page responses, so I usually just resort to playing with settings until it works. Anyway, here’s a couple of common causes for the blank page in IIS 7 that I’ve come across.

Check if Service attribute in SVC markup equals your implementation class.

Check endpoint contract name. It has to be exactly full name of your interface. Don't add assembly name, it won't work.

Check <serviceMetadata httpGetEnabled="true" />. If false, you get blank page too.

And 4th change which helped me (but I have no idea why): Remove behavior name <behavior name=""> and remove behaviorConfiguration attribute from service element. It becomes default so the behavior will be used anyway.

WCF Rest Web Service Returning Blank Page, WCF Rest Web Service Returning Blank Page returns my test json from my database hosted at discountasp: Code: Okay, ignore me. Then I realized I had no authentication providers allowed in IIS or in the web.config :)  I'm having some issues getting a WCF Rest web service I created working with DiscountASP. The goal is to call a web service located at /thelandsocial/map and return JSON. This is all working great in the local debug instance, but when placed on the discountasp servers I get a blank page returned with no JSON.

  1. Be sure you made an Application Pool with active user like this: https://stackoverflow.com/a/19654633/2148387

  2. Be sure you created Web Application where your WCF is hosted

  3. Check if AppPool and WebApp are running

  4. Enable Directory Browse in your Web.config like here: https://stackoverflow.com/a/19630263/2148387

Publishing WCF web service on my local IIS : The Official Microsoft , I have created a WCF web service and when i execute it from the web service methods don't seem to work, it just returns a blank page, http://www.​kebabshopblues.co.uk/2013/09/20/hosting-a-wcf-service-library-project-in-iis-8-0​-windows-8-0-net-4-5/ Can you confirm me that the config file is correct? IIS Hosting is illustrated below in detail with the desired coding as well as screenshots to understand the process. Step 1 − Start Visual Studio 2012 and click File → New → Web site. Select “WCF Service” and Location as http. This will host the service in IIS. Click OK. Step 2 − The code behind the interface is given below.

when i write http://localhost on browser only blank page? : The , same as when i am running wcf service on local iis it is not responding? what can #2 More Reasons Why You Might Get A Blank Page in IIS7. For example, an IIS application host process that only serves static HTML pages is typically configured differently than an IIS application host process that serves ASP pages or ASP.NET applications. Configuration of an IIS application host process also varies depending on the version of IIS that is hosting the application. The host process

How to host my WCF service in my website? - html, WCF Service response “HTTP/1.1 400 Bad Request” on shared hosting - hosting. the usual config issues one faces moving a service from local IIS to shared hosting. GMT Content-Length: 0 In Safari/Chrome this manifests as a blank page. For me the issue was the following; we added MVC to a solution with routing.

WCF Error Handling - wcf pandu, WCF FAQ, WCF Fundamentals, it's all about wcf,Searches related to all about wcf to the client by defining a fault contract and returning the error as a FaultException. is complete, you should migrate the services from WCF Service Host to IIS. Click Start Project and leave the Command line arguments dialog box blank.

  • You'll need to show the web.config serviceModel element contents to get a meaningful answer. Not sure what you mean by setting the URL as the "binding".
  • I think he means "endpoint"
  • Sory, edited the question
  • @PatrickHofman, Yes, if I remove the address I can browse but why? Shouldn't I provide adress.
  • But the main problem is this: If I specify endpoint adress correctly I get blank page. If I dont specify any endpoint adress I can get the service. So what is the problem with the coerrct endpoint adress. Why am I getting blank page?
  • Thanks, this really clarified the issue
  • I have another computer and on this computer even if I provide address I can see my service. But on the other computer I can't see. I really don't understand why.