“Herein is love made perfect with us, that we may have boldness in the day of judgment; because as he is, even so are we in this world. There is no fear in love: but perfect love casteth out fear, because fear hath punishment; and he that feareth is not made perfect in love.” (1 John 4:17-18; ASV)
How does love give us "boldness on the day of judgment?" John explains that when we walk in love, we walk as Christ did, and this gives us great encouragement. It casts out any fear we might have regarding judgment. If we still fear judgment, it might be because Christ is not first in our lives (Matthew 6:33), and, consequently, we are not walking in love.
Just trust our Lord that He will eliminate this fear of judgment as we continue to follow Him. He has promised that He is able to make us stand (Romans 14:4-5).
Don't worry if you find that you are unable to achieve this confidence. God did not grant this to me for many years. In my case, He first had to humble me - the most painful thing I had ever experienced - before He'd lift me up. (And He still has a lot of lifting to do on my behalf.)