for Scriptural Teachings on this Topic)
Some men who never heard the name of Jesus have lived according to the light that God gave them; for God has given to every man that is born into the world, according to the revelations we have received, His Spirit. He has given unto every man and woman His Spirit, not the gift of the Holy Ghost, but His Spirit by which they are led and guided. Some call it the light of conscience, the voice of conscience. No man ever committed a wrong that listened to that voice without being chided for it, whether he be Christian or heathen, whether he has lived according to the light of the Gospel or been in entire ignorance of it. Every man has within him a spirit which comes from our Great Creator, and if we grieve it not it leads us, guides us, though we may not know the Gospel, as has been the case with many thousands and millions of human beings. It leads all the children of men when they listen to it; it leads them in the path of peace, in the path of virtue, in the path of happiness; but if they violate that spirit or grieve it, if they go contrary to its monitions, if they harden their hearts against and sin against it, then it departs, and another spirit takes its place, namely, the spirit of the evil One.
Thus it is that the heathen, many of them have lived lives most exemplary, lives which are the admiration of posterity. Men not confined to one race, not to one nationality, but men of every race, men of every clime, men of every language, have received the same spirit and have been enlightened by it and their lives have been noble and admirable, and no doubt have been acceptable to God our eternal Father. Therefore, when you think about your grandparents whom you have known, when you think about your parents or some other relatives whom you have known, who died in ignorance of the Gospel, you have known their lives, you have known how good their desires were, you have known how they conformed to the law so far as they understood it, how moral they were, how exemplary, how correct in their conduct, in their conversation and in their dealings—when you think of these, you need not be afraid that they have lost anything because they died in ignorance of the Son of God.
I tell you that God's providence is over all His children, and He will reward every man and every woman according to his or her works, and He will reward those who have lived exemplary lives, those who have been moral, whether they be heathen or Christian, whether they have known the name of Jesus or not, whether they have the Bible, or the Koran, or some other book, or no book at all; whatever may have been their condition and circumstances, if they have lived according to the light that God has given them, and to laws that they understood, God will reward them, and will eventually bestow every blessing upon them which they are capable of receiving. (Journal of Discourses, 26:83-86)