A friend of mine asked me a question recently, whether or not baptism is essential for the forgiveness of sins. Most people who believe that it is focus on the words of Peter:
And Peter said to them, “Repent and be baptized every one of you in the name of Jesus Christ for the forgiveness of your sins, and you will receive the gift of the Holy Spirit." - Acts 2:38 (All verses ESV)
This appears to be very clear, that you must be baptized in order to receive forgiveness of sins and the gift of the Holy Spirit. On the other hand, we have passages like John 3:16 that paint a different picture of salvation:
For God so loved the world, that he gave his only Son, that whoever believes in him should not perish but have eternal life. - John 3:16
What appears to be important in John is simply the act of belief. Baptism is not mentioned. Proponents of this argument usually cite the thief on the cross as another proof that baptism is not necessary:
“One of the criminals who were hanged railed at him, saying, “Are you not the Christ? Save yourself and us!” But the other rebuked him, saying, “Do you not fear God, since you are under the same sentence of condemnation? And we indeed justly, for we are receiving the due reward of our deeds; but this man has done nothing wrong.” And he said, “Jesus, remember me when you come into your kingdom.” And he said to him, “Truly, I say to you, today you will be with me in Paradise.”” - Luke 23:39-43
This passage is very important to understanding the process of salvation. The words of Peter say to "Repent and be baptized" but the thief clearly didn't have the opportunity to be baptized and yet he was certainly saved. The words of Jesus in John 3 say that belief in him is what matters, but do not mention repentance, and yet you would be hard pressed to find anyone who argues that only belief matters. Even the demons believe in God (James 2:9).
We need to be careful that we don't put too much stock in a single verse, but instead consider all of scripture if possible. The thief on the cross believed in Jesus, repented of his sins and was saved.
One way to look at this passage is as an extraordinary circumstance. Truly there was no way for this man to be baptized, nor to listen to a sermon, and he had a direct dispensation from the Lord Jesus Himself that he would be saved. But I think to do this is to ignore what the passage is meant to teach us.
In looking at this I think it's key to realize that the thief's action was a combination of Peter's exhortation to repent and Jesus' teaching that belief in the son leads to eternal life. It seems that the process of salvation is believe (in Jesus), repent (of your sins), and receive (the gift of forgiveness of sins and of the Holy Spirit).
There is little argument there, but that leaves us with the question of what Peter meant when he said "repent and be baptized" and I think this is where context becomes so critical. In verse 22 Peter addresses his audience, and that audience is "Men of Israel." This is a key point, because the entire system of Jewish law is about external action as evidence of internal state. The Jews show their allegiance to God by obeying the law. When speaking to Jews, Peter would need to explain what external action would represent their internal change of repentance, and this action was baptism.
I do not believe that Peter here is insisting that baptism is necessary for salvation, but rather that baptism is how you show that you have repented of your sins. For the thief on the cross this was not necessary because he had shown his repentance through his action (defending Jesus to the other thief), and it was not necessary that he do anything other than believe and repent.
Another key point is that baptism was viewed as a way of identifying yourself as a proselyte. Paul addresses this very topic in 1 Corinthians 1:13-17 when he says that Jesus did not send him to baptize, but to preach. This was in the context of division in the church, and Paul was thankful that he hadn't baptized anyone because he didn't want them to have bragging rights.
It is interesting that Paul does not ever preach that you must be baptized in order to be saved (not sure about Romans 6. Maybe we'll come back to that later). In Romans Paul writes:
“But what does it say? “The word is near you, in your mouth and in your heart” (that is, the word of faith that we proclaim); because, if you confess with your mouth that Jesus is Lord and believe in your heart that God raised him from the dead, you will be saved. For with the heart one believes and is justified, and with the mouth one confesses and is saved.” - Romans 10:8-10
Paul's audience is not only Jewish (although it does include them). Paul was called to take the name of Christ to the Gentiles (Acts 9:15) who did not have the same emphasis on external signs of internal change. Thus Paul focused on belief in Christ, and then how one should act after professing that faith.
That does not mean that baptism is unimportant. Indeed Paul did baptize people, as it is written in 1 Corinthians 1:14 & 16, and Jesus Himself underwent baptism. Paul was baptized immediately after the scales fell from his eyes. The New Testament is filled with examples of people being baptized after confessing their faith in Christ. Let's not forget the "great commission" in Matthew:
And Jesus came and said to them, “All authority in heaven and on earth has been given to me. Go therefore and make disciples of all nations, baptizing them in the name of the Father and of the Son and of the Holy Spirit, teaching them to observe all that I have commanded you. And behold, I am with you always, to the end of the age.” - Matthew 28:18-20
We would be remiss to ignore all of this evidence (and a direct command from Jesus Himself) and view the sacrament of baptism as unimportant. But it is not the waters of baptism that save, it is repentant faith in the resurrected Lord Jesus Christ that offer salvation and forgiveness of sins.