diff --git a/html/index.html b/html/index.html
index 62d3c0c..ebcbcef 100644
--- a/html/index.html
+++ b/html/index.html
@@ -175,7 +175,8 @@
Scores
const startGameButton = document.getElementById('startGameButton'); // Start button reference
function connectWebSocket() {
- socket = new WebSocket('ws://localhost:9105');
+ url = "ws://" + window.location.hostname +":"+ (parseInt(location.port) + 100);
+ socket = new WebSocket(url);
socket.onopen = function () {
console.log('WebSocket connection established');
};