What is the main purpose of the book of Galatians?
The letter's main purpose is to correct the Galatians' turning from Paul's Gospel of pure Grace toward Judaizers who taught that Law observance was necessary. It declares that believers are not under Law but under Grace, and that no one can merit favor with God; the only proper response is believing what God has said.
Les teaches that the Galatians had not completely turned their backs on Christianity or on Christ, but they had turned from Paul's Gospel of pure Grace and were now believing the Judaizers, who said they maybe had to practice the Law. This was not another Gospel but a perversion—something fooled with and no longer pure. So the purpose of the letter was to say, "You're not under Law, you're under Grace." Even today the heart cry is the same: people are not under anything legalistic but under Grace, and Grace means there is nothing a person can do to merit favor with God. The only thing to do is believe that everything God has said is true and that everything He has done has been from His direction.
I marvel that ye are so soon removed from him that called you into the grace of Christ unto another gospel: