THE verb khalasa means 'to become pure, clear, free or safe', and akhlasa is 'to purify something'. So ikhlaas means 'purification' – the purification of one's belief and intention, which leads to sincerity in worship. Ikhlaas can also indicate the purification of one's deeds from riyaa' (showing off), in complete obedience to Allah alone.
Every Muslim has to focus on knowing the true meaning and purpose of life. Then he must formulate an all-encompassing intention to utilize his moral, spiritual, mental, emotional and physical resources to purify his soul. A person making decisions based on this higher purpose, aspiring to attain Allah's approval is living and striving; otherwise he is just existing and wasting his efforts.
Say, "Shall we inform you of the greatest losers as to their deeds? They are those whose effort is lost in the life of this world, while they think that they are doing good in [their] work." (Quran, 18:103-104)
Ibn Katheer said,
“This is general, referring to everyone who worships Allah in a way that is not acceptable, thinking he is correct in doing so and that his deeds will be accepted. But he is mistaken, and his deeds will be rejected.”
Ikhlaas (sincerity) is a condition for Allah's acceptance of the righteous actions that are done in accordance with the Qur'ān and Sunnah. It is when the worshipper intends all of his deeds for the acceptance of Allah, for His rewards and His favours.