There is no doubt that one of the obligations upon the Muslim is that he earn for himself and his family a pure and halal sustenance. Abu Hurayrah narrated that the Prophet (sallallahu alaihi wa sallam) said:
||"O People! Allah is al-Tayyib (Pure), and He only accepts that which is pure! Allah has commanded the believers what He has commanded the Messengers, for He said, 'O Messengers! Eat from the pure foods, and do right,' and He said, 'O you who believe! Eat from the pure and good foods We have given you.'"
Then the Prophet (sallallahu alaihi wa sallam) mentioned a traveller on a long journey, who is dishevelled and dusty, and he stretches forth his hands to the sky, saying, "O my Lord! O my Lord!" - while his food is unlawful, his drink is unlawful, his clothing is unlawful, and he is nourished unlawfully; how can he (expect to) be answered? It is noticed in this hadith that the Prophet (sallallahu alaihi wa sallam) emphasised this person's impure earnings by detailing the fact that his food, clothes, drink and nourishment were all obtained from the impure.
From this hadith, we learn that both the prophets and the believers have been commanded to eat from the tayyibdt, or the pure things. Purity is achieved when one earns his sustenance in a halal manner, and then uses it to buy halal food. So, if a person buys pure food from stolen money, this will not be accepted from him. Likewise, if one earns money from permissible means, then uses it to buy impermissible items, such as intoxicants, this too will not be accepted from him. Only when both of these conditions have been met - the way one earns money and the way one spends it - will Allah's acceptance be gained.
Another hadith affirms the above:
||"Whoever gives charity equivalent to a date, from his pure earnings and Allah only accepts pure then Allah will accept it with His right hand, then He will nurture it for its companion, like one of you nurtures his foal, until it becomes like a mountain." 
So charity that is given from impure earnings will not be accepted by Allah, no matter how much is given, whereas charity given from pure earnings will be accepted by Allah, even if equivalent to a date!
Furthermore, there are a number of narrations that signify that earning through halal is an obligation upon every Muslim.It is because of this that Islam encourages working. The taking of a profession is encouraged because it is one of the best ways that a person can ensure earning pure sustenance. Umar ibn al-Khattab said,
||"I see a man that impresses me, so I ask, 'Does he have a profession (through which he earns money)?' So if they say, 'No,' then he falls from my eyes (and I do not respect him)." 
So great is the status of halal sustenance that Islam has not looked down upon manual labour. Instead, it has given it a very high place, due to the fact that manual labour is, in general, a very honest profession. The Prophet (sallallahu alaihi wa sallam) stated,
||"No one has ever eaten any food that is better than eating what his hands have earned. And indeed the Prophet of Allah, Dawud, would eat from the earnings of his hands." 
In this hadith, we are told that the most honourable way to earn money is through manual labour, for even the Prophet Dawud would earn his sustenance by making armour and selling it. Furthermore, the Prophet (sallallahu alaihi wa sallam) said,
||"The prophet Zakariyya was a carpenter." 
This great Prophet of Allah, who took care of Maryam the mother of Isa, used to earn his livelihood through the noble profession of carpentry.
In fact, even the Prophet of Allah (sallallahu alaihi wa sallam) used to earn from his own hands. Once, he (sallallahu alaihi wa sallam) stated,
||"Allah did not send any prophet except that he used to be a shepherd of sheep."
So the companions asked, "Including you, O Messenger of Allah?" He replied,
||"Yes, I used to be a shepherd for the people of Makkah, in return for some qararit (i.e., coins of copper)." 
The Prophet (sallallahu alaihi wa sallam) was not embarrassed or ashamed to inform his companions that he used to work as a shepherd in return for a very small amount of money (qararit).
As mentioned earlier, there are two aspects to halal sustenance, the first involving earning through halal means (as discussed above), and the second entailing spending only on halal items so as to ensure purity in what a person eats, drinks and is nourished on.
||"I sometimes return home to my family, and I find a date fallen on my bed, so I pick it up to eat it, but then I fear that it might be from charity, so I throw it away." 
On another occasion, the Prophet (sallallahu alaihi wa sallam) could not sleep all night, tossing and turning. So his wife asked him, "O Messenger of Allah! You spent the night awake, tossing and turning?" He replied,
||"I found a date last night under my side, and ate it. (Then I remembered) that we had (in our house) some dates that were meant for charity. So I feared that the date (that I ate) was of it." 
Subhan Allah! The Prophet (sallallahu alaihi wa sallam) ate one date, forgetting that he had some dates in his house that were meant to be distributed to the poor, and this caused him to have a sleepless night for fear that it might have been from the dates of charity! So how is it that this accidental morsel, which a person would hope to have been forgiven on the basis of innocent intention even had it been haram, caused our beloved Prophet (sallallahu alaihi wa sallam) so much unrest and discomfort, while one of us might earn his or her entire living through means that are haram without a doubt, and yet still enjoy a deep sleep at night?
The Companions, too, were careful about how they earned their sustenance. Once, a servant of Abu Bakr's came to him with some food, so he ate from it. The servant then asked him, "Do you know where this came from?" He replied, "From where?" The servant responded, "I practised astrology once in the times of Jahiliyyah — even though I am not an expert in it, except that I managed to trick the other person. [10 ]So he paid me, and gave me what you ate!" Hearing this, Abu Bakr put his finger in his mouth and forced himself to vomit up the food, until there was nothing left in his stomach. [11 ]A similar incident is reported from 'Umar ibn al-Khattab, when he was given some milk by his servant, and then found out that the milk was from the camels that were meant for charity. [12 ]In yet another indication of the piety of the early generations, Sa'ad ibn Abi Waqas, one of the famous Companions of the Prophet (sallallahu alaihi wa sallam), was once asked, "Why is it that your prayers are responded to, amongst all of the other Companions?" So he replied, "I do not raise to my mouth a morsel except that I know where it came from and where it came out of." 
In conclusion, the Prophet (sallallahu alaihi wa sallam) gave an example contrasting the person who takes from this world excessively, not caring how he earns his money, with the person who takes from it moderately, ensuring that his earnings are halal. He (sallallahu alaihi wa sallam) said,
||"What I fear for you after me (is) what will be given to you from the magnificence and beauty of this world, except that good never brings about evil. The fruits that are harvested in spring cause death (for the animal that eats it), or brings it close to death, except for the one that eats khadir. [14 ]So when it (the animal) eats this until its stomach is full, it faces the sun and releases its bowels and urinates (i.e., with ease), then pastures again. And verily this money is enticing and sweet.
So how great is the Muslim companion (to it), who gives it to the poor and the orphan and the way-farer. So he who acquires it justly, and puts it in its proper place, then how great a helper it is! But he who takes it unjustly, is like the one who eats but is never satisfied, and it will be a witness against him on the Day of Judgement." 
In this beautiful hadith, the Prophet (sallallahu alaihi wa sallam) drew a parable between the one who does not care how he earns, but rather takes everything he finds, like the animal that eats from all types of crops in the spring. Spring is the season that gives crops which are generally not suitable for animals to eat. So this is an indication of a greedy person, whose only desire is to increase his or her wealth, regardless of the consequences. Such a person is never satisfied, but rather eats, and eats, and eats, until he or she is destroyed, or is almost about to be destroyed, just like the animal that eats excessively. However, the wise person chooses with care how to earn sustenance, and picks the right types of food to eat. Such a person only takes what is needed, and does not become excessively involved with earning more than the basic needs. Such a person will live a comfortable life, just like the animal that eats the right crop in moderate quantities. Furthermore, such a person will be able to earn more, when the need arises, just like this animal will be able to pasture again when it needs to. How beautiful, then, is this money when earned properly and spent properly! And how evil it is, when earned improperly, and spent improperly!
1 Reported by Ahmad (2/328), Muslim (2/703), and al-Tirmidhi (5/220) from Abu Hurayrah.
2 Reported by al-Bukhari (#1410) and others.
3 There are various wordings of this narration, one of them being, "The seeking of halal sustenance is an obligation upon the Muslim." However, none of these narrations are authentic. Some scholars, such as al-Sakhawi, consider the hadith to be hasan due to all of its weak chains (see his al-Maqasid al-Hasanah, # 801), whereas others, such as al-Albani, hold it to be weak (see al-Mishkat, # 2781). In any case, the meaning of the hadith is without a doubt correct.
4 Kanz al-Ummal, (4/123).
5 Reported by al-Bukhari (2/10) and others.
6 Reported by Muslim (# 2379) and others.
7 Reported by al-Bukhan (2/48) and others.
8 Reported by al-Bukhari (# 232) and Muslim (# 1069). It was not allowed for the Prophet (sallallahu alaihi wa sallam) or his family to eat from charity.
9 Reported by Ahmad in his Musnad (2/183 and 193), and considered authentic by al-Arna'ut in his checking of Sharh al-Arba in (p. 198).
10 Meaning that he was not an astrologer by profession, but pretended to be one in order to gain some money. The practice of astrology is itself a form of shirk, thus this money was tainted by the evil of astrology and the evil of cheating.
11 al-Mishkat(# 2786).
12 al-Mishkat (# 2788). It is not allowed to benefit from the animals that are given in charity unless the Muslim ruler distributes it to those that deserve it.
13 Shark al-Arbdin, p. 275.
14 A green crop that is not of the fanciest type of harvest
15 Reported by al-Bukhari (# 1465) and others.
Extracted from “15 Ways to Increase Your Earnings” published by Al Hidaayah UK