JOEL - Baptism for the dead is the proxy performance of the ordinance of baptism for one deceased. We believe that all mankind must have the opportunity to receive the Gospel and obtain eternal life with God. One of the requirements of this is the ordinance of baptism:
"Verily, verily, I say unto you, they who believe not on your words, and are not baptized in water in my name, for the remission of their sins, that they may receive the Holy Ghost, shall be damned, and shall not come into my Father's kingdom where my Father and I am." (D&C 84:74, See also Mark 16:16)
The ordinance of baptism must be performed here on earth. This is obviously impossible for those who have passed on without having the opportunity of hearing and accepting the gospel while here on earth. The ministry of Christ in the spirit world was for the benefit of those who had died without hearing the gospel or the fulness of it (1 Pet. 4:6). We believe that all those who die without having heard of the gospel will have the chance in the spirit world after they die. The purpose of this is to give them the opportunity to accept or reject it according to their own choice. If they accept the gospel they are elligble for admitance into the kingdom of God after the resurrection. However, this would still require the ordinance of baptism which they cannot now do for themselves. The ordinance of baptism for the dead allows us to stand in for our deceased ancestors and provide this required saving ordinance, which they can either accept or reject.
Baptisms for the dead, which was a New Testament practice(1 Cor. 15:29), are now performed in our temples for the ancestors of members who have been identified through genealogical research. Men are baptized for deceased men and women for deceased women.
"Is this for remission of sins, receiving the Holy Spirit, to enable families to be together in eternity if they were not previously bapised and active members of the church?"
The answer is yes to all these questions. There are, however, other saving ordinances besides baptism, that are also performed in the temple for those who have died, that are also required for families to be together forever.