Why is Proctor arrested at the end of the Act?
At the end of ACT III, Proctor himself is arrested, despite his original intent of going to court being to free his wife Elizabeth. He arrives with several depositions at the beginning of the Act, all of which should be enough to release Elizabeth and the wives of Giles Corey and Francis Nurse, the men who accompany Proctor to court; however, it becomes apparent very quickly that the court is not interested in hearing any evidence that disproves the girls' claims - mostly because they've rushed in their punishments and many people have already hanged. Admitting the girls are wrong would be admitting those people were innocent and killed unjustly.
The girls are brought in to be questioned about Mary's deposition stating that there is no witchcraft and begin to accuse her of bewitching them; though Mary attempts to stay strong, Proctor sees it is becoming difficult for her to withstand the girls' claims and finally admits that he had an affair with Abigail and that she is after Elizabeth so that she can have John for herself. The judges send for Elizabeth; John and Abigail are turned to face the other direction so that they cannot make eye contact with Elizabeth. John tells the court that Elizabeth "cannot lie," however, she does lie in order to save her husband's reputation - she says that the adultery accusation is false in an attempt to save John's reputation, but it essentially damns him to prison because he has already admitted his sin.
Immediately following this, Abigial begins her theatrics again, with her sights still set on Mary. Mary eventually falls and then accuses John Proctor of bewitching her. When the judge shows signs of believing her, John shouts out "God is dead!" - his commentary that all that is good and right is being put aside for these outlandish and false tales. At the end of the act, John is arrested and later executed for witchcraft.
Trying to save Elizabeth from being condemned as a witch, Proctor calls out Abigail as a harlot, confessing to the court that he had an affair with Abigail. Ironically, Elizabeth Proctor (known for always being truthful) lies to the court about the affair, hoping to protect John from the shame of being a known adulterer. Abigail, with the help of the other girls, then turns her eyes back to Mary Warren, accusing her of bewitching them. Despite Proctor trying to encourage Mary to stand strong on the truth, and to hold to her profession that the entire proceedings have been based on lies, Mary begins to cave under the pressure. She turns on Proctor herself, accusing him of witchcraft and of coercing her to go with him to overthrow the courts. Mary claims that she is turning back to God, leaving the courts to charge and arrest Proctor.