As-salamu `alaykum wa rahmatullah

A chapter I took from one of my books… very insightful.

“… Know that not everyone is suited to be your friend. The Prophet (sallallahu `alayhi wa sallam) said, “A person is upon the Deen of his friend, so let each of you look to whom you befriend.” [Abu Dawud, 4833]

One must consider a number of characteristics (when choosing a friend):

He must be intelligent and sound of mind (astute) and generous among the people and he should not be an immoral person or an innovator or someone who desires and covets this world.

As for astuteness, then that is the capital. As ‘Ali (radhi’Allahu `anhu) said:

“Do not accompany the ignorant,
Beware of him, beware of him!
For how many of an ignorant one has destroyed,
A forbearing one when he goes to him.
A person is only weighed against another,
When he sides and walks with him.
And for everything there are indeed,
Similarities and a comparison.
Just like there is between two hearts,
A sign and an indication, when they do meet.”

So how will the matter be (for you) when the foolish ends up harming you although he intends to benefit you! For this reason, the poet said:

“I feel safe from an enemy who’s endowed with sound intellect ,
But I fear a friend who has been seized with mental illness.
For soundness of mind is of one type; I know its ways
But insanity manifests itself in so many numerous ways.”

For this reason, it is said: ‘Severing ties with the foolish means to draw closer to Allah, the Most High.’ Likewise, there is no good in the companionship of an immoral person because the one who fears Allah will never persist in a major sin, but as for him who does not fear Allah, then nobody is safe from the havoc he causes.

Allah Ta’ala said,

“… And do not obey one whose heart We have made heedless of Our remembrance and who follows his desire and whose affair is ever [in] neglect.” [al-Kahf: 28]

As for good character, then ‘Alqamah ibn Qays (rahimahullah) summed it up in his final advice to his son as he was on his deathbed:

“O my son, if you ever feel the need to befriend and accompany men, then accompany the one who protects you when you help him, adorns you if you walk with him, and supplies you when your provisions run out. Accompany the one who when you stretch forth your hands in goodness, he stretches his hand too, if he sees merit from you, he remembers it, and if he sees bad from you, he remedies it. Accompany the one who gives you when you ask, who steps up when you are silent, and who consoles you when calamity overtakes you. Accompany the one who believes you when you speak, entrusts you when you engage in work, and if you fall out, he prefers you to the fallout.”

In such cases, it is said:

‘Your real brother is he who stays with you
Who harms himself in order to help you
When hard times break you and scatter you
He becomes dispersed just so he can fix you’

But before all that, he must be knowledgeable after having attained wara’ (piety), so that you can benefit from his knowledge too. Luqman said to his son, “O my son, sit with the scholars, crowd them with your knees! For indeed, hearts come to life with words of wisdom just like the dead earth comes back to life with the downpour of rain.””

– Mukhtasar Ihya ‘Ulum al-Din, by Imam al-Ghazali.