Facebook Messenger Alternative

The new Facebook Messenger in the browser sucks at its best. It’s very annoying to use, heavy, slow and hard to use. It sucks!

But Facebook provides a nice browser messenger for mobile devices, but only in specific cases. Usually, you will be stuck with this message to install Facebook crap:

Install Messenger

Alternative

This solution is oriented to Firefox for Desktop, but you can find alternatives for your browser.

  1. You will need to install this two plugins:

  2. After restarting Firefox, open Modify Header Value (HTTP Headers) options:

    • Add-ons > Extensions > Modify Header Value (HTTP Headers) double-click > Options
  3. Now, add the following rule:

    • URL: https://m.facebook.com/*
    • Header Name: User-Agent
    • Header Value: Mozilla/5.0 (Mobile; Windows Phone 8.1; Android 4.0; ARM; Trident/7.0; Touch; rv:11.0; IEMobile/11.0; NOKIA; Lumia 520) like iPhone OS 7_0_3 Mac OS X AppleWebKit/537 (KHTML, like Gecko) Mobile Safari/537

    If you want always be redirected for mobile website, add another rule like the previous one, but with the url https://www.facebook.com/*

  4. Open the url https://m.facebook.com/messages and you see the messenger like if it was in your phone.

  5. But when you are writing to someone, if you press Enter a new line is inserted instead of sending the message. You will need a Greasemonkey script to make it work:

    • Add-ons > User Scripts > New user script…
  6. Fill the following fields:

  7. Paste and save the following script:

    // ==UserScript==
    // @name        Facebook Messenger - Send on Enter
    // @namespace   http://www.rigon.tk/documentation/facebook-messenger
    // @description Send message on Enter press
    // @include     https://m.facebook.com/messages/read/*
    // @version     1
    // @grant       none
    // ==/UserScript==
    
    var input = document.getElementById("composerInput");
    
    input.addEventListener("keyup", function(e) {
      var keynum;
      if(window.event) { // IE
        keynum = e.keyCode;
      } else if(e.which){ // Netscape/Firefox/Opera
        keynum = e.which;
      }
    
      // On ENTER press
      if(keynum == 13) {
        // input.form.submit();  // Causes refresh
    
        var event = document.createEvent('HTMLEvents');
        event.initEvent("click", false, true);
    
        var send = input.form.querySelector("button[name=send]");
        send.dispatchEvent(event);
      }
    });
    
  8. Reload or open the url https://m.facebook.com/messages
    And that’s it!