I am referring to the Bible.
1 Corinthians 15:29 says "Else what shall they do which are baptized for the dead if the dead rise not at all? why are they then baptized for the dead?"
LDS believe Paul was well aware that Christians were performing baptisms in behalf of the dead. He referred to this practice as evidence that there will be a resurrection from the dead. If not, he reasoned, then why are baptisms for the dead being performed?
Non-LDS give other explanations for the verse. One is that Paul was referring to a Pagan practice, not a Christian practice. We know that Christians practiced baptisms for the dead in the first centuries of Christianity. At some point in history (not sure of the century), the Catholic Church condemned the practice as heresy.
I believe that the New Testament Christians practiced baptisms for the dead and it was a correct practice. Paul was referring to this correct Christian practice when he wrote 1 Corinthians and made his case for the reality of the resurrection.
Apparently this practice lived on in the church or at least in parts of the church for a few centuries. I believe the Catholic Church saw no doctrinal basis for the practice and condemned it.
In our day, the Lord reinstitued this ancient Christian ordinance through the Prophet Joseph Smith. Many LDS in this thread have explained how the practice was started in our time. I quoted LDS scriptural sources that explain how the practice fulfills prophesies relating to our time.