Do you order people to devoutness and forget yourselves, when you recite the Book? Will you not use your intellect? (Surat al-Baqara; 44)
An intelligent and experienced person well acquainted with the Qur'an can detect the minor faults and weaknesses in the faith of people and advise them. This is a praiseworthy quality, yet that does not mean he himself is free of mistakes. On contrary, he must strive to avoid committing the same errors; otherwise, he may earn Allah's disapproval rather than reward for his advice.
It is unlikely that someone able to recognize a fault in others will fail to recognize it in his own soul. Undoubtedly, he is also aware of his own wrongdoings and sins. This shows that he is very insincere. For instance, it would be hypocritical for a liar to call people to truth and sincerity, or for someone who does not pray to call others to regular prayer. An advisor who fears Allah would surely be the first one to avoid committing sins. The conclusion to the verse above, "Will you not use your intellect?" makes it clear that people should practice what they preach.
Deviant attitudes such as the desire to control others, have one's word respected or be influential underlie hypocritical behavior that lies outside Qur'anic morality. This kind of motivation will neither protect the interests of the religion nor correct the mistakes and sins of Muslims. If one gives these warnings out of the fear of Allah and out of concern that these errors should not be committed, he is more concerned that he does not commit the same sins himself. But when he counsels and advises only to attain status, respect and esteem, the manipulation of faith-related issues for personal benefit will only lead to great disappointment in the Hereafter.
When a Muslim sees another committing an error that he himself is guilty of, he can let him know that he too is trying to correct that same mistake. Then the two can encourage one another toward improvement and by doing so, earn the pleasure of Allah.