Cut to the heart: repent and be baptized
37 Now when they heard this, they were cut to the heart, and said to Peter and the rest of the apostles, “Brothers, what shall we do?” 38 Peter said to them, “Repent and be baptized, every one of you, in the name of Jesus Christ for the forgiveness of sins, and you will receive the gift of the Holy Spirit. 39 For the promise is to you and to your children, and to all who are far off, even as many as the Lord our God will call to himself.” 40 With many other words he testified and exhorted them, saying, “Save yourselves from this crooked generation!” 41 Then those who gladly received his word were baptized. There were added that day about three thousand souls.
Peter answers the crowd's question with repentance, baptism, forgiveness and the Spirit's gift.
The hearers are cut to the heart and ask what to do. Peter tells them to repent and be baptized for forgiveness, and he promises the Spirit to them, their children and those far off. About three thousand are baptized that day.
The response comes before any appeal. Peter had urged no decision. He argued from Scripture and known facts, and the argument did its own work. Their question comes from men just told they crucified their Lord. It assumes the situation is desperate and that something might still be done, and both prove correct.
Peter's answer has four parts. They must repent, changing the mind that produced the crucifixion. They must be baptized, every one of you, in the name of Jesus Christ, the public act by which each person changes sides. Forgiveness of sins is the outcome, and the reason a crowd guilty of this crime is not turned away. The Holy Spirit's gift, which they have watched all morning, is promised to them.
Forgiveness and the Spirit come together, offered to former opponents with no probation and no course of instruction. Later the reception of uncircumcised Gentiles is settled because God gave them this gift Acts 11:17, on the precedent set here. Peter stretches the promise to all who are far off, the language the prophets used for the nations, long before the church works out what it means.
Those baptized came from the perplexed who asked, not from the mockers. A question honestly asked was honestly answered.
settled What this mark means