The more you pray and read the Bible, the closer you will get to God. He will start to speak to you. He may speak to you through a Bible verse that will address your situation. He may give wisdom to people around you to guide you toward right choices. He may also speak to you through the “still, small voice” of the Holy Spirit.
When you are a saved Christian, the Holy Spirit dwells inside your spirit. In this way, you can be directed by the Holy Spirit from within. He will strike your conscience when you consider doing something that will hinder you. He will bring knowledge to you directly by speaking to you in that still, small voice. Basically, that means that you hear His voice in your heart, soul and mind. It just comes. His voice is different from your own thoughts. The reason it is referred to as the still, small voice is because the words of the Holy Spirit can be easily never heard if you aren’t close enough to God to realize it’s Him, or if you dismiss His voice as your own thoughts.
Hearing God’s voice takes practice and time. You have to decipher between your own thoughts and the words of God. One way to do this is to ask yourself, “would I have known this on my own? Is this a different approach than one I would usually take?” Over time, God will help you to discern between your own thoughts and the voice of the Holy Spirit.
It has been my experience that when I make an effort to get to know God by studying the Bible and praying regularly, I hear the voice of the Holy Spirit more clearly and more often. God will reward your efforts to know Him better.