localhost refusing connection in WCF
<p>I am learning WCF(C#) while I am hosting WCF using console application. It is showing no errors but when I type <a href="http://localhost:8080/" rel="nofollow noreferrer">http://localhost:8080/</a> in browser browser saying it is refusing connnection. Please provide me solution.<a href="https://i.stack.imgur.com/i6wmw.png" rel="nofollow noreferrer">enter image description here</a></p>

<p>my code in configuration file is given below</p>

<pre><code>    &lt;services&gt;
  &lt;service name="MyService.MyWService" behaviorConfiguration="mexBehaviour"&gt;
    &lt;endpoint address="HelloService" binding="basicHttpBinding" contract="MyService.IMyWService"&gt;
    &lt;/endpoint&gt;
    &lt;endpoint address="HelloService" binding="netTcpBinding" contract="MyService.IMyWService"&gt;
    &lt;/endpoint&gt;
    &lt;endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" /&gt;
    &lt;host&gt;
      &lt;baseAddresses&gt;
        &lt;add baseAddress="http://localhost:8080" /&gt;
        &lt;add baseAddress="net.tcp://localhost:8090"/&gt;
      &lt;/baseAddresses&gt;
    &lt;/host&gt;
  &lt;/service&gt;
&lt;/services&gt;
&lt;behaviors&gt;
  &lt;serviceBehaviors&gt;
    &lt;behavior name="mexBehaviour"&gt;
      &lt;serviceMetadata httpGetEnabled="true" /&gt;
    &lt;/behavior&gt;
  &lt;/serviceBehaviors&gt;
&lt;/behaviors&gt;
</code></pre>