Many people claim to have the Holy Spirit but can't tell what they did to receive it. Or if they know, it may have something to do with the sinner's prayer, which is not scriptural.
Here is the test to see if we have the Holy Spirit or not:
1 John 4:1-3 Beloved, do not believe every spirit, but test the spirits, whether they are from Elohim; for many false prophets have gone forth into the world. The Spirit of Elohim is known by this: Every spirit which confesses that Yahshua Messiah has come in the flesh is from YAHWEH. And every spirit which does not confess that Yahshua Messiah has come in the flesh is not from Elohim; and this is the Anti-Messiah which you heard is coming, and now is already in the world.
If we believe the Messiah was part deity and part human, we don't have the Holy Spirit. The Messiah was totally human, otherwise we have no hope of eternal life. We are to follow by his example. He was immersed by John the Immerser. He was tortured; he was impaled on a stake; he died and was buried. After three days and three night he was resurrected by YHWH his Father. He died to pay the debt we owed for our sins because the wages of sin is death.
How do we receive the Holy Spirit?
The first requirement is to REPENT. As with Hebrew thought, there are more than one thing required by a verb.
In this case, we are to bring all of our sins to mind and ask forgiveness for them. Additionally, we are to turn from our sins and turn to YHWH and the Torah. The Torah (first five books of the Bible) is often thought to mean law or laws. It actually means instruction in righteousness. It's our Heavenly Father's instruction manual on how to live our lives. It does contain some laws. Without law there would be chaos.
Here's apostle Peter's description of how to receive the Holy Spirit:
Acts 2:38 And Peter said to them, Repent and be baptized (immersed), each of you in the name of Yahshua the Messiah for the forgiveness of sins, that you may receive the gift of the Spirit of Holiness.
The repent process can take a fairly long time. When we have finished repenting, we should be worthy to be immersed.
We agree to several conditions before being immersed. These must be renewed each year at Passover.
Once we are immersed, we die to our old self and come up out of the water as a new sinless person. When Messiah returns and we remain faithful, we will be resurrected with a new body.