Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. SQL Server
  3. Question
SQL Server

From ws vs wss, which one should I use for my game?

Asked by Ranjana Admin Jan 18, 2022 1.3K views 4 answers
Share

About this question

I know it's generally considered best practice to just always use SSL but my game has a tonne of communication back and forth between clients and server (lots of positional updates per second and I want as little delay/bandwidth/processing used as possible) so I'm wondering if it's necessary?

Your answer

4 Answers

Thai Yacht Latest answer

Answered on Sep 17, 2026

Use wss and stop thinking about it. Plain ws will be blocked outright by any page served over https, and a fair number of corporate proxies drop it even when the browser does not. The certificate handling is the only real extra work and a reverse proxy takes care of that for you. Worth remembering that not every game needs a socket at all, plenty of small browser titles like Drift Boss run entirely client side and only talk to a server for the leaderboard.
Was this helpful?

Thai Yacht

Answered on Aug 25, 2026

For a game with lots of positional updates I would still use wss. The TLS cost is small next to the risk of an open ws socket on hotel wifi, and you can keep payloads tight. Same idea as anything else you send off a shared network, even booking a Phuket day boat through Rent Yachts Thai.

Was this helpful?

Mark Tuan

Answered on Mar 17, 2026

Thank you for the the recommendation to use WSS from Admin. While it may seem like an overhead due to the high volume of communication, the security benefits far outweigh the potential risks of using unencrypted WebSockets. Protecting sports games user data and ensuring a secure environment is crucial, especially if your game involves competitive elements or any form of monetization. It's better to invest in security now than to deal with the consequences later.



Was this helpful?

Ranjana Admin JanBask Expert

Answered on Jan 19, 2022

From ws vs wss, you should use the secure WebSockets protocol in your product.

Given (extremely little) information you provided about the details of your game*. Only general answer is possible to the question**:

What is the worst thing that could happen if I don't enable wss?
If you design and build a system disregarding common security precautions:
at best nothing will happen;

then there is a whole gray area where you might either end up losing an opportunity, or have to allocate excessive resources to make up for the initial decision;

at worst - there is no limit to bad things that may happen.
* It is impossible to evaluate the impact of using unencrypted communication without knowing in full detail what the game is. Particularly: How are you capitalizing on games? Are users playing against each other? Are users incentivised to cheat (either materially or in form of score tables)? The information required for such an analysis should also include future development of the game, for example what to do if it catches on and you change the model from free and decide to capitalize in future.

** An audit of all possible dangers for using unencrypted communication in a product must take into account so many factors that it would quickly exceed the costs of implementing proper encryption techniques.
Was this helpful?

More SQL Server discussions

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.

Latest SQL Server Blogs

Guides, tips and career advice on SQL Server from JanBask experts.