If you came to a bridge and were told by a guide that it was safe to cross, then the way to have trust in your guide would be crossing it. God is trustworthy, therefore His instructions are also trustworthy (Psalms 19:7), so the way to trust in God is by obediently trusting in His instructions, which is why the Bible frequently connects our faith in God with our obedience to Him. For example, in Matthew 23:23, Jesus said that faith is one of the weightier matters of the law. In Romans 1:5, we have received grace in order to bring about the obedience of faith. In Romans 3:31, our faith upholds God's law. In Psalms 119:30, he chose the way of faith by setting God's law before him. In Revelation 14:12, those who kept faith in Jesus are the same as those who kept God's commandments. In John 3:36, it equates believing in Jesus with obeying him. In Hebrews 3:18-19, it equates disobedience with unbelief. In Numbers 5:6, it describes disobedience as breaking faith.
The way to believe in God is by directing our lives towards being in His likeness through being a doer of His character traits. For example, by being a doer of good works in obedience to God's law we are testifying about God's goodness, which is why our good works bring glory to Him (Matthew 5:16), and by testifying about God's goodness we are also expressing the belief that God is good. Likewise, the way to believe that God is a doer of justice is by directing our lives towards being a doer of justice in obedience to His instructions, the way to believe that God is holy is by being a doer of His instructions for how to be holy as He is holy, and so forth. This is exactly the same as the way to believe in the Son, who is the radiance of God's glory and the exact likeness of God's character (Hebrews 1:3).
Likewise, the reason why there are many verses that say that the way to have eternal life is by believing in the Son and many verses that say that the way to have eternal life is by obeying God's commandments is because God's commandments are His instructions for how to believe in the Son. In other words, God's word is His instructions for how to believe in God's word made flesh.
So the significance of our works in obedience to God's law has absolutely nothing to do with trying to contribute anything towards earning our justification as the result, but rather the significance is that it is the way to have faith, and it is by that faith alone that we are justified.