Unwanted Prosody login upon refresh


When a “Jitster” is in a conference via web browser, and they press F5 (or if they refresh by clicking in the address bar,) the user ends up at this screen (in the screenshot,)

How can I redirect them away from this screen when that happens? I’d rather send them back to my website’s homepage than have them end up at this screen.

If anyone could tell me where the html is for that login screen (probably in Prosody somewhere?) then I can stick a redirect inside of it, and that would be great. Alternatively, if there’s a better way to handle it, please let me know.

Thanks Jitsi buds!

You may try to put the following codes into /usr/share/jitsi-meet/body.html

const LINK = "https://jitsi.org";
let failedAttempt = 0;
function interceptLoginRequest() {  
  try {                             
    // if conference is already started, dont wait for an auth request
    if (APP.conference.isJoined()) return;            
    // check if login or IamHost button is created in DOM
    const _button = document.getElementById("modal-dialog-ok-button");
    if (!_button) throw("button is not created yet"); 
    let labelKey;                   
    try {                           
      labelKey = Object.values(_button)[0].return.memoizedProps.labelKey;
    } catch {                       
      // do nothing                 
    if (labelKey === "dialog.login") {
      // if this is a login screen, redirect to custom page
      window.location = `${LINK}`;
  } catch(e) {                      
    failedAttempt += 1;             
    if (failedAttempt < 20) {
      setTimeout(function() {interceptLoginRequest();}, 1000);



This is working perfectly! Thank you very much!