By hijacking these five words out of the context, many cults and sects have used them to teach that a New Testament Christian can go to hell AFTER believing on Christ, and AFTER becoming a Son of God. They usually define their own version of just what "good works" are actually "good works" enough to be "truly" saved or to maintain salvation. The Bible clearly shows the relationship of faith and works as it progressed through the ages, ultimately culminating in the perfect faith, work, a sacrifice of the Lord Jesus Christ. Because of His perfect grace, love, work, and faith he pleased the Father once and for all so that those who would believe on Him thereafter would have "eternal life" and "never perish."
James 2 simply displays and expounds on an AGES old concept, how that faith and works ALWAYS appear together, as those who have true faith in God seek to obey His Word.
In the New Testament, the gospel of our Lord Jesus Christ offers an all in one package deal, unlike other ages, offering with HIS work, HIS faith, and HIS sacrifice Godward as the complete salvation of the sinner.