On the one hand, we all want to condemn suicide in the strongest possible terms. On the other hand, we want to have compassion for the poor tormented souls who've blundered into a broken place where hope was fatally elusive. Our religions speak to both sides of this human tragedy.
On the condemnatory side of religious beliefs about suicide — I would actually prefer to call this the life-affirming side — is the belief that murder, including self-murder, is the worst of all sins because it takes away God's greatest gift, the gift of life.
We did not give ourselves life, so we are not allowed to usurp God's right to take it away from us. Deuteronomy 30:19-20 reminds us that God has set before us life and death, and our job is to choose life, no matter how difficult that choice might be:
"I call heaven and earth to record this day against you, that I have set before you life and death, blessing and cursing. Therefore choose life, that both thou and thy seed may live. That thou mayest love the Lord thy God, and that thou mayest obey his voice, and that thou mayest cleave unto him, for he is thy life and the length of thy days..." (KJV)
Seen in the light of this text, suicide is not just a rejection of life but a rejection of love and a rejection of God. No despair, no matter how deep, should drive us to throw away every supremely good thing in life.
One of many Christian Testament texts expressing a similar anti-suicidal sentiment is 1 Corinthians 3:16-17:
"Know ye not that ye are the temple of God, and that the Spirit of God dwelleth in you? If any man defile the temple of God, him shall God destroy; for the temple of God is holy, which temple ye are." (KJV)