You know the secrets of the world and that which is concealed in the recesses of every living thing (Yom Kippur Machzor).
In this prayer, we acknowledge that God knows all our hidden, innermost thoughts. We then come to vidui (confession) and verbalize all our misdeeds and faults. This process seems a bit contradictory. Since we have just stated that God knows all that we do, feel, and think, why do we relate everything verbally to Him?
We have many thoughts and feelings which we would like to disown. We may consider them so reprehensible that we hate to admit that we harbor them. We therefore repress them, keep them out of our awareness, and make believe that they do not exist.
A make-believe world is not real. Telling ourselves that these unacceptable thoughts and feelings do not exist will get us nowhere. From the depths of our unconscious minds, they will continue to clamor for recognition and expression. They either succeed in coming to the fore, or they drain our energies as we force them back down.
Our Sages suggested a solution. There is no point in concealing our thoughts or feelings anywhere, for regardless of where they may be hidden, God knows them. We shouldn't worry, for His love is unconditional, and He loves us in spite of our shortcomings. Since God knows that we have these thoughts and feelings, then at least as far as He is concerned, the secret is out. If so, we might as well be aware of them ourselves. And now, the need for repression disappears.
Therefore, we acknowledge our shortcomings verbally, not in order to tell God, but to tell ourselves that which He already knows.