diff --git a/src/app/rx-stomp.config.ts b/src/app/rx-stomp.config.ts
index 139561d1ffe74f664ac97b9bbea5f2883b9d88a3..f36fcda1b7a855d93f37475d57f9f9436f1fa899 100644
--- a/src/app/rx-stomp.config.ts
+++ b/src/app/rx-stomp.config.ts
@@ -2,7 +2,8 @@ import { RxStompConfig } from '@stomp/rx-stomp';
 
 export const ARSRxStompConfig: RxStompConfig = {
   // Which server?
-  brokerURL: `ws://${window.location.hostname}:8080/ws/websocket`,
+  brokerURL: (window.location.protocol === 'http:' ) ?
+    `ws://${window.location.hostname}:8080/ws/websocket` : `wss://${window.location.hostname}/api/ws/websocket`,
 
   connectHeaders: {
     login: 'guest',