Sayyiduna Utbah bin Abd (may Allah be pleased with him) narrated from the Messenger of Allah (peace and blessings be upon him) that he (peace and blessings be upon him) said: "Those who are killed are of three kinds: A believing man who strives in the path of Allah with his wealth and his life, until, when he meets the enemy, he fights until he is killed. This is the martyr who takes pride, who will be in the tent of Allah beneath His Throne; the Prophets surpass him only by the rank of prophethood. Second, a believing man who has burdened himself with many sins and wrongs; he strives with his life and wealth in the path of Allah until he meets the enemy, and he fights until he is killed. This is a purifier for his sins and wrongs; indeed, the sword wipes away wrongs. And he will be admitted through whichever gate of Paradise he wishes, for it has eight gates, and Hell has seven gates, and some of them are better than others. Third, a hypocrite man who outwardly strives with his life and wealth in the path of Allah, until he meets the enemy, and he fights until he is killed. This one will be in the Fire, for the sword does not wipe away hypocrisy."
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 14382