إِنَّهُمْ فِتْيَةٌ آمَنُوا بِرَبِّهِمْ وَزِدْنَاهُمْ هُدًى
Truly! They were young men who believed in their Lord (Allah), and We increased them in guidance. [Surat Kahf: Ayah 13]
This verse shows the direct relationship with believing in Allah and being granted guidance. Thus, the implication is that the stronger your belief and the more pure it is, the more Allah will increase you in guidance and righteousness. And Allah Knows best.
Check Tafsir ibn Kathir for more details inshaAllah.
__________________