Darxis
Darxis

Reputation: 1570

SignalR Client returns HTTP error 400 Bad request when websocket is used

I am using a SignalR Client connection using HubConnection. When calling Start(), an System.Net.WebException is thrown with the following message:

The remote server returned an error: (400) Bad Request.

The server response is:

Not a valid web socket request.

I am running Windows Server 2012 R2 with IIS 8.5

What could be the problem?

Upvotes: 2

Views: 5382

Answers (1)

Darxis
Darxis

Reputation: 1570

The problem was with the configuration of IIS.

You have to install the WebSocket Protocol support in order to connect to SignalR using WebSockets.

enter image description here

Upvotes: 9

Related Questions