KJV Below (Link to NIV)
21 Was not Abraham our father justified by works, when he had offered Isaac his son upon the altar?
22 Seest thou how faith wrought with his works, and by works was faith made perfect?
23 And the scripture was fulfilled which saith, Abraham believed God, and it was imputed unto him for righteousness: and he was called the Friend of God.
By the way of example James turns to Abraham. To be sure, he makes it clear that Abraham’s faith is what made him righteous, not his deeds. But his deeds were the natural outgrowth of his faith. Why? Because faith is fundamentally relational. Faith trusts, which is why he could go to the point of offering up Isaac (as Hebrews notes, he reasoned he could receive Isaac back from the dead). And faith comes out of a relationship, which his why Abraham is called a friend of God.
How much do you trust God? Would you be able to offer up your kids, your spouse, your parents, your friends? (read Luke 14:26 in light of that). What does it mean to be a friend of God? Not only are you God’s friend, but (more importantly) God is your friend. What does it mean to have God as your friend?