url to open facebook messenger app if installed, else open web messenger

Harry picture Harry · Apr 9, 2017 · Viewed 18.7k times · Source

I am looking for a single url to open facebook messenger chat session across different devices:

  • On mobile, if fb messenger app is installed, it opens fb-messenger://user-thread/
  • On mobile, if fb messenger app is not installed, it opens http://m.me/
  • On desktop, it opens http://m.me/

Example: For Google map, I just need use href="http://www.google.com/maps/place/{{lat}},{{lng}}", it will automatically open Google map app if installed, else it open google map on browser.

Thank you.

Answer

Bcf Ant picture Bcf Ant · Apr 9, 2017
http://m.me/<FACEBOOK_PAGE_USERNAME>

For example:

Broadcast Football