Allah raises the level of people in two ways: (a) Belief in Him and (b) Knowledge of Him. This is established in the following verse of the Qur’an. Allah said:
“Allah raises the level of those who believe and those who are endowed with knowledge.” [Al-Qur’an 58:11]
Acquiring knowledge of Allah is the most important obligation on every Muslim because Allah ordered seeking knowledge (i.e. the knowledge of Himself) prior to declaration of the Shahadah. He said:
“And know that there is no deity worthy of worship but Allah then seek forgiveness for your sins.” [47:19]
To emphasise seeking knowledge before doing any action, Imaam Al-Bukhari used the above verse as a basis for a chapter in his all famous Sahih. He entitles that chapter: “Knowledge before speech and action”.
Book of Knowledge: [Sahih Bukhari Vol: 1 Ch 11]


Excellence of knowledge
Allah said: “Allah (Himself) is witness that there is no deity worth of worship except Him, and the Angels and the men of learning (are also witnesses to this). Maintaining His creation in justice, there is no god save Him, the Almighty, the Wise.” [3:18] Notice that Allah (subhanahu wa ta’ala) in the Ayat started the witnessing to the fact that “there is no deity worthy of worship but Himself” with Himself, then He follows it saying that this is also the witness of His Angels and then He follows it by the people who possess knowledge. This verse definitely emphasises the position of the people who are endowed with knowledge above those who are without it.
Allah said:
“... Are those who know equal with those  who do not know? But only men of understanding will pay heed.” [39:9]
He said:
“... Indeed those who fear Allah from  His servants they are the knowledgeable, Indeed Allah is the Mighty, the Most Forgiving.” [35:28]
He said:
“And these similitude We coin for mankind, but none will grasp their meaning except those of knowledge. [29.43]
In all  of the above verses we clearly see the very high rank that Allah Himself endowed on those who possess knowledge.
N.B. The knowledge above is only in reference to knowledge of Islam.
Allah said:
“Ask the people of Remembrance if you do not know.”
This is because understanding Allah’s Rulings is based upon the investigation and deductions of the learned.
Abu Dardaa, radhiallah ‘anhu, said that the Messenger of Allah (sallallaahu ‘alaihi wa sallam) said: “Those people endowed with knowledge are the inheritors of the prophets.”
[Hadith Hassan, Abu Dawood, ibn Majah, At-Tirmidhi, ibn Habaan].
He (peace be upon him) also said:
“Whosoever Allah wishes good for, He bestows upon him understanding of the Deen.” [Bukhari and Muslim).
He bestows upon him an understanding of Deen means that He will allow him to be taught the Qur’an and the Sunnah. It is common knowledge that there is no higher position than that achieved by the prospects and that there is no greater honour than that of inheriting from that  noble position [i.e inheriting from the prophets (on them be peace)].
To acquire this very coveted positions needs serious striving to acquire the knowledge they came with (i.e. the knowledge of Allah’s deen).
He (sallallaahu ‘alaihi wa sallam) also said:
“The superiority of a learned man over a worshipper is like my superiority over the ordinary men from among any companions.” [At-Tirmidhi. Hadith Hassan].
Looking at this Hadith you will observe (a) how he (peace be upon him) linked knowledge with the position of prophethood, and (b) how he lowered the level of the person who  does action without knowledge.
Any worship (‘eebadah) that a worshipper perform must be based on knowledge, because if it is lacking then the action would not be ‘eebadah but mere ritual.
The messenger (sallallaahu ‘alaihi wa sallam) also said:
“The superiority of a learned man over a worshipper is like the superiority of the full moon over the other stars.  [This Hadith is Hassan].
‘Ali, radhiallah ‘anhu, said to Kaamil:
“O Kaamil, knowledge is better than wealth. Knowledge protects you while you have to protect your wealth. Knowledge is a judge, while wealth have to be judged on. Wealth decreases when it is expended while knowledge purifies when it is given.
Ali, radhiallah ‘anhu, said in a poem:
“Glory is for none but the learned,
Guided are they – and proofs for seekers of guidance.
Every person is measured based on how much it (knowledge) he mastered, 
The ignorant are to the learned their enemies,
Succeed with knowledge and live energetically forever,
Men are all dead, only the possessors of knowledge are truly alive.”
The Excellence of Learning
Allah said: “And the believers should not all go out and fight. Of every troop of them, a party should go forth, that they (who are left behind) may gain sound knowledge in religion, and that they may warn their folk when they return to them, so that they may beware.” [9:122]
And His saying:
“...Ask the people of Remembrance if  you do not know.” [16:43]
The Messenger of Allah (sallallaahu ‘alaihi wa sallam) said:
“Whoever  treads a path seeking knowledge therein, Allah directs him to a path leading to ‘Al-Jannah’ (Paradise).” [Hadith Hassan]
He (peace be upon him) also said:
“The quest for knowledge  is a compulsion on every Muslim.” [Hadith Hassan]
N.B. The knowledge referred to above is knowledge in Deen because that is the only knowledge that is Waajib. The people who use this hadeeth to represent seeking after every type of knowledge are misusing it.
Abu Dardaa’ said:
“To learn of one issue (in deen) is better for me than to pray the entire night”
He also said:
“The scholar and the seeker of knowledge are the partners in the sharing of good. Other men are hungry and there is no good in them.”
Fath Al Musilee (radhiallah ‘anhu) said:
“Would the sick person who is not fed or given anything to drink or given any medicine, not die?” The people replied: “Surely!”
He said: “It is the same with the heart, it would die if knowledge and wisdom is withheld from it.”
Indeed he spoke the truth because the nourishment and enlivening of the heart is through knowledge and wisdom, just as food is nourishment for the body.
Whoever does not acquire knowledge of the deen of Islam, has a sick heart and its death is inevitable. However, he is not aware of it, because his love for this world destroys his perception.


The Excellence of Teaching
Allah said: “... and that they may warn their folk when they return to them, so that they may beware.” [9:122]
What is implied here is teaching and guiding them.
And the saying of Allah.
“And (remember) when Allah took a covenant from those who received the Scripture, (He said): You are to expound it to mankind and not to hide it..[3:187]
This ayat demands that those who are endowed with knowledge   should teach it. While the verses that follows show that it is Haram to conceal it.
Allah said:
... But verily, a party of them knowingly conceal the truth [2:146]
And He also said:
... He who hides it, verily his heart is sinful [2:283]
Allah praises the one invites with knowledge. Allah said:
And who is better in speech than he who invites to Allah and does good works... [41:33]
And the saying of Allah:
Call unto the way of your Lord with wisdom and good exhortation, and reason with them in the better way... [16:125]
‘Ali said that the Messenger of Allah (peace be upon him) said to him: “If Allah guides a man through your help, it is better (for you) than red camels.” [Bukhari and Muslim]
N.B. Red camels at that time were from among the peoples’ most precious possession.
He (peace be upon him) also said:
Whoever acquires knowledge and keep it concealed Allah will bridle him with a bridle of fire on the Day of Resurrection. [Abu Dawood, Ibn Majah, At-Tirmidhi]
He (sallallaahu ‘alaihi wa sallam) also said:
Verily Allah, His angels, the inmates of the heavens and the earth, even the ant in its hole and the fish in the sea send salutation on the one who teaches good to the people. [Its chain is Hassan]
He (sallallaahu ‘alaihi wa sallam) said:
If the son of Adam dies, all his works are stopped except three. A charity that is continuous, useful knowledge or a righteous child who supplicates for him [Muslim]
The Messenger of Allah (sallallaahu ‘alaihi wa sallam) said:
Whoever guides or directs to good, then he gets the same amount of blessing as the one who does it. [Related by Muslim]
And Allah censures those who speak on His behalf without any knowledge and some of the scholars consider it an even more heinous sin than shirk based on the following verse. Allah said:
“Say (O Muhammad): My Lord has only forbidden indecencies, those of them that are apparent as well as those that are concealed, and sin and rebellion without justice, and that you associate with Allah in worship that for which He has sent down no authority, and that you say about Allah that which you do not know.” [7:33]
Therefore, speaking on behalf of Allah without knowledge is the greatest sin with Allah and the one for which He will assign the severest punishment.
Clarifying what aspect of knowledge is a compulsion on every Muslim (Fard ‘Ain).
The Messenger of Allah (sallallaahu ‘alaihi wa sallam) said:
“Seeking knowledge is a compulsion on every Muslim.”
This Hadith is referring  to the knowledge of that aspect of the Deen that will save someone from the Fire.
Therefore, what is important for each one of us is to be certain that we know what Knowledge  is compulsory  for each person to save himself from the Fire.
Before discussing this, however, it is important to know that we must keep on doing righteous deeds until death, otherwise if anyone changes then all the worship that he did before is going to be worthless. If a person fasts a long hot day and then breaks his fast a few minutes before Maghrib, then his fast is void. Likewise, if a person prays a long Salaat and before making Tasleem passes wind, his prayer is nullified.
Life may look like a long journey, but if a person apostatises before the end, he loses everything, and all his deeds are rendered worthless and he would be subjecting himself to dwell in the Fire forever.
Allah said:
“Verily, Allah forgives not (the sin of) setting up rivals in worship with Him, but He forgives (sins) others than that to whom so ever He pleases... [4:116]
This verse establishes that Allah does not forgive Shirk (i.e. setting up rivals in worship with Him), therefore the most important knowledge that a Muslim must seek is the knowledge of Shirk and all that relates to it, from Tawheed and ‘Aqeedah (beliefs), etc. It is mandatory on every Muslim to learn these aspects before anything else and not listen to those who say: “These are theoretical issues, instead keep busy with matters  that have action.”
Our answer to them is that “Aqeedah (matters relating to Eemaan) is the greatest of all matters in Islam because Eemaan comprises of the following three aspects (a) believing in the heart, (b) stating with the tongue and (c) acting with the limbs upon what is believed in and stated.
Know, my brothers and sisters that all acts of worship  would be rewarded based on what the heart intends for that particular action thus making it (the heart) the most important organ of the body.
Related Story

Belief is practical matter because it is the action of the heart. The proof of this statement is the saying of Allah:
... But He will call you to account for that which your hearts have earned... [2:225]
This verse indicates what the heart earns. What is earned is the action and it is this that we will be called to account for. Therefore, we can conclude that the action of the heart, which is the beliefs present in it are the most serious action.
Is there not a difference between two persons who say. “Laa Illaha Illa Allah” (there is no deity worthy of worship but Allah), while one has a heart filled with correct beliefs, and the other is a hypocrite who disbelieves in everything in Islam? Surely there is, the first will go to Al-Jannah (Heaven) and the other will be in the lowest depth of the Fire of Hell. Why is this so? Because of the beliefs in his heart, which are its action.
The messenger (sallallaahu ‘alaihi wa sallam) stayed in Makkah for thirteen years inviting people to ‘Laa Illaha Illa Allah’, and  all those things that relates to it, from Tawheed, ‘Aqueedah and Shirk.
When the messenger (sallallaahu ‘alaihi wa sallam) sent Mu’adh to Yemen he said to him:
“You are going to a people who possess a Book, so let the first thing  you call  them to be to testify to ‘Laa Illaha Illah Allah’, and if they acknowledge this, then tell them that Allah made obligatory on them five Salawaat every day...”
From the above examples we can conclude that knowing Allah and performing Tawheed of Allah is the most glorious knowledge in existence. Therefore, the most glorious action a person has to occupy and fill his heart with is knowing his Lord.
The glory of any knowledge is based on the thing studied.
Is there anything more glorious than Allah, the Glorified? Definitely not. Therefore, the knowledge that relates to the study of Allah, what are His rights on us His creation, what He loves and what He does not would therefore be the most glorious knowledge there is in this universe.
Above we have proved what is compulsory knowledge for every Muslim, male or female to seek i.e. any knowledge that helps him or her to perfect their worship for Allah.
The knowledge that is compulsory can be classified:
(a) The first obligation on any Muslim who has reached the age of maturity is to learn about the Shahadah i.e. “There is no deity worthy of worship but Allah, Muhammad is the messenger of Allah.” And to understand their meanings.
That knowledge which helps us to know Allah and teaches us His rights on us. This includes the knowledge of the ‘Tawheed of Allah’ in all its various forms i.e. Tawheed of Lordship, Tawheed of His Names and Characteristics and Tawheed of ‘Eebadah. It also includes any knowledge that would help us to understand any thing that would negate any of the above aspects of Tawheed. This would fall under the category of Shirk. Every Muslim must learn about Tawheed and Shirk.
(b) Knowledge of His Messenger, Muhammad (peace be on him). This includes understanding his purpose as a messenger, his rights on us, our relationship with him,  This knowledge is important because through the messenger (sallallaahu ‘alaihi wa sallam) we learn how to worship Allah and perform His rights i.e. the messenger came to invite to Tawheed and to fight mankind to keep away from worship other than Him.
Allah said:
“Verily we sent to each nation a messenger to invite to the worship of Allah and to avoid Taghoot.”
(c) Any knowledge which helps us to know about the other four fundamental principles of the religion namely, Salaat, Zakaat, Fasting and Hajj. These are pillars of Allah’s deen and each Muslim must have knowledge about each one of them as soon as it becomes an obligation on him so that he can perform it as Allah wants him to.
(d) that which is halal and that which is haram of social and business transactions that relates to anyone is also an obligation on him to know.
(e) that knowledge which relates to the affairs of the heart, that which is praiseworthy and which every Muslim must try to develop and nurture, like patience, thankfulness, good character, truthfulness and sincerity, etc and from that which is blameworthy and which every Muslim must try to avoid because they are Haram and therefore can cause someone to be thrown into the Fire. Some examples of these are hatred, jealousy, pride, doing things for show, dishonesty, anger, enmity and miserliness, following the desires, etc. 
As for knowledge which is Fard Kifiyah; i.e. that which is a collective duty, meaning that it is not a duty on every individual, but it a group of individual undertakes to acquire this knowledge, all other individuals will be exempted from this duty, and the entire community will be free from negligence to acquire this branch of knowledge. If no one embarks on seeking this type of knowledge then the entire community is accountable. Examples of this type of knowledge are:
* An in depth study of the Islamic Law.
* Study of the basic sciences, industries and professions that are vital necessities for the welfare of the community like doctors of medicine, nurses, accountants, contractors, etc.
The Muslims have definitely gone astray in their understanding of their priorities as to which knowledge they must concentrate on and as such we find them put a priority on a knowledge that is not compulsory on them to know about.
The messenger (sallallaahu ‘alaihi wa sallam) warns us of this, he said:
“From among the portents of the Hour are (the following):
(1) Religious knowledge will be taken away (by the death of the learned men)
(2) Ignorance (of Religion) will prevail.
(3) Drinking of alcoholic drinks (will be very common).
(4) There will be prevalence of illegal sexual intercourse. [Al-Bukhari: Vol 1 No. 80]
The Messenger of Allah (sallallaahu ‘alaihi wa sallam) said:
“Allah does not take away the knowledge, by taking it away from (the heart of) the people, but takes it away by the death of the religious learned men until when none of the (religious learned men) remains, people will take as their leaders ignorant persons who when consulted will give their verdict without knowledge. So they go astray and they will lead the people astray.” [Al-Bukhari: Vol 1 No. 100].


The importance of good companionship
Choosing and having good companions is extremely important for many reasons and from many aspects. 


1. Mankind cannot live alone; every individual must live and interact with others, and when interacting with others one either influences or is himself influenced.
2. Those people whom you sit with and make your friends are inevitably going to fall into one of two categories. They will either be good individuals - who guide and encourage you towards what is good and help you to accomplish that which Allah has ordered, or they are going to be bad - encouraging you to do what is pleasing to Satan, that which misleads you, and leads you to the Hell-Fire. 
3. When the Prophet, sallaallahu ‘alaihi wa sallam, was sent with the mission to establish Islam, he did not do it on his own. Rather, Allah chose for him companions who accompanied him and who carried the Message until it was complete. 
These three aspects show the importance of having good companions, companions who are righteous. Such a companion will help you to do what is good and remind you of Allah, he will enjoin what is good and forbid what is evil. These aspects also show the importance of avoiding befriending bad companions, because such a companion will have a bad effect upon you, they help you to do those deeds which are displeasing to Allah and which lead to the Hell-Fire. 
The Prophet, sallaallahu ‘alaihi wa sallam, gave a good similitude regarding this. He, sallaallahu ‘alaihi wa sallam, said: “The case of the good companion and the bad companion is like that of the seller of musk and the blower of the bellows (iron-smith). As for the seller of musk, he will either give you some of the musk, or you will purchase some from him, or at least you will come away having experienced its good smell. Whereas the blower of the bellows will either burn your clothing, or at least you will come away having experienced its repugnant smell.” [Al-Bukhaari and Muslim] 
The Prophet, sallaallahu ‘alaihi wa sallam, explained the matter of good companionship, so that no room is left for doubt or confusion, when he, sallaallahu ‘alaihi wa sallam, said: “A person is upon the religion of his close friend, so beware whom you befriend.” [Abu Daawood and At-Tirmithi] 
This means that a person will be upon the same methodology as his friend, the same path as his friend, the same nature, manner and behavior as his friend. So we must be careful whom we befriend. There is an Arabic saying: ‘Your companion is what pulls you to something.’ So if your companion is good, he will pull you towards that which is good. He will order us with what is good and forbid us from what is evil. If he observes us committing sins he would warn us, if he becomes aware of our shortcomings he would advise us, and if he finds a fault in us he would cover it and not disclose it to others. About this, the Prophet, sallaallahu ‘alaihi wa sallam, said:  “…Whoever conceals (the fault of) a Muslim, Allah will conceal his fault on the day of Judgment.”  [Abu Daawood] 
So should you see a fault in your brother, you should wish to remove that fault from him and not expose it to the people. This is what is required by brotherhood and again stresses the importance of choosing friends who are upon the correct way, who are loyal, and who hide your faults whilst ordering you with good and forbidding you from evil, who stand beside you and support you, and co-operate with you upon all that is good. 
This principle is important from the standpoint of how the religion is to be established, and from the standpoint of what brotherhood is and what it does. Indeed, the reason that one takes a companion is to help him establish Islam, and to help him worship Allah. We find a good example in the Prophet Moosaa, may Allah exalt his mention, the one whom Allah chose and spoke to. When Allah sent him to Pharaoh, he (Moosaa), may Allah exalt his mention, said as Allah informs us saying (what means): “And appoint for me a helper from my family, Haaroon - my brother; increase my strength with him, and let him share my task (of conveying Allah’s Message and Prophethood), that we may glorify You much and remember You much.” [Qur’an; 20: 29-34] 
Moosaa, may Allah exalt his mention, wanted his brother to support him and help him, protect him and accompany him. This is exactly what the believers do for one another. For the thing that binds the believers together and makes them brothers is the bond of faith. The Prophet, sallaallahu ‘alaihi wa sallam, said: “There are three characteristics; whoever has them will taste the sweetness of faith: That Allah and His Messenger are more beloved to him than all else, that he loves a person and does not love him except for the sake of Allah, and that he would hate to revert to unbelief just as he would hate to be thrown into the Fire.” [Al-Bukhari and Muslim]
Thus the connection between the believers is based upon faith and sincere brotherhood. Beware against taking any companion if such companionship is based upon other than this, for if you were to do that you would then bite your hands in grief. Just as the unjust ones will bite their hands in grief. Allah Says (what means): “And (remember) the Day when the wrong-doer (oppressor, polytheist etc.) will bite at his hand, he will say:  ‘Oh! Would that I had taken a path with the Messenger. Ah! Woe to me! Would that I had never taken so-and-so as a friend! He indeed led me astray from the Reminder (the Quran) after it had come to me….’” [Qur’an; 25:27] 
And Allah Says (what means): “And whosoever turns away from the remembrance of the Most Beneficent (Allah), We appoint for him Satan to be a Qareen (intimate companion) to him.” [Qur’an; 43:36] 
So all of the physical togetherness that you see around you, which is based upon other than faith will be wiped away on that Day, and it will be a source of misery and torture for them. Allah Says (what means):  “Friends on that Day will be foes one to another except the pious.” [Qur’an; 43:67]
Article source: http://www.islamweb.net/emainpage/