Websocket traffic - costs associated?

What is the name of the domain?

What is the error number?

What is the error message?

What is the issue you’re encountering

Do i have to pay for websocket traffic that does trough CF?

What steps have you taken to resolve the issue?

I found this, but it doesn’t state any pricing, only how to enable it

WebSockets can be easly enabled at Cloudflare dashboard for your domain name with a single click, therefrom it’s not a paying subscription service. Free of charge to use with your domain name having proxied :orange: DNS records.

If you’re using a Cloudflare Worker with combination with WebSockets:

Then yes, is billable as follows:

1 Like

Hi fritex, thanks for responding.

My consequent question is about this:

When Cloudflare releases new code to its global network, we may restart servers, which terminates WebSockets connections.

How often does CF release new code to its global network?

Websockets close with the error 1006 when this occurs. Furthermore related to the restarting/retry, error 1001 so both sides (client and origin server) are aware that the WebSocket termination is only a transient event, and that they can expect to immediately re-establish a connection again on retry.

Regarding server restarts, Cloudflare does not publish a schedule for code deployments that may restart servers. However, Cloudflare’s architecture is designed for high availability, so such events should be infrequent.

The solution is just to make sure you have reconnect logic. Users being disconnected due to Cloudflare or general network problems isn’t uncommon.

I’m not sure there’s really better advice than just make sure you have reconnect logic implemented in your code/application.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.