We all struggle with temptations to do things that are categorically wrong and sinful. These temptations are high visibility, and hopefully easily overcome by turning to Jesus.
However, we also face a constant temptation to do the right thing for the wrong reasons: So we can be independent. So we can be in control. So people will like us. To get respect. To win worship. To be somebody. To be accepted by the crowd. So we don’t have to depend on Jesus or anyone else.
These "motives of the heart" are low visibility, and hard to recognize in ourselves. How do we get on top of these motives when they lure us away from faith and dependence on Jesus? The solution is always the same. It's always turning, or returning, to Jesus. No matter how far we go astray, the only solution is to return to the completer of our faith. "Therefore, let us fix our eyes on Jesus, the author and perfecter of our faith" (Hebrews 12:2).
The secret to having the right motives is to so closely identify ourselves with Jesus that we can say with a clean heart, "Your will be done. I want to live my life for the will of God. I have no agenda but God and no agenda but God's. I love you God with every ounce of my energy and the sum of my strength. I'm giving my life to communion with you and making disciples for you. You are all I really want in life. Be glorified in me."