Facebook chat application for Linux command line

Default featured post

It is really true that Linux is a such powerful operating system. Apart from its security, freedom and flexibility, it provides all facilities for every type of user from novice to professional. In other word, it satisfies needs of all users from different categories.

Again Linux provides more options for geeks and people who prefer to work in command line. In the one of my posts I mentioned about command line based Twitter application and in this post I introduce you to command line Facebook chat application. For achieving to mentioned purpose we need Ekg2 application.

Installing the application is quite easy and fortunately the application is available in Ubuntu repository by default. In order to install Ekg2 application type following line in your command line,

$ sudo apt-get install ekg2-core

After installation completion, type ekg2 in your terminal. Then the application will open and you need to configure it. For configuration, type the following lines in the application environment.

> session -a xmpp:[email protected]
> session password YOUR_FACEBOOK_PASSWORD
> save
> connect

In the first line you set your Facebook user name account. You should replace YOUR_FACEBOOK_USERNAME expression with your user name and also bear in mind to not miss @chat.facebook.com part. Your Facebook user name is the same name in front of Facebook URL when you are in your profile page. For example,

> https://www.facebook.com/kasra.mp?ref=tn_tnmn

In above example the user name is kasra.mp. Again keep in your mind that you should be in your profile page to get such URL not in the time line page.

Then in the second line you set your Facebook password obviously. When you enter your password, the application does not encode it with * character and it shows your real password. Hence, be careful at the time of entering your password.

In the next step you save setting and finally you command the application to connect to the server which is Facebook.

In order to chat with someone just type the following command in the application command interface,


Replace PERSON NAME with the name of the person which you want to start chatting with him/her.

For finishing your chat press ALT+K and for exiting the application type quit in the application command line.

More information can be found in the man page of the application.