1 Corinthians 6:9-10 states that the unrighteous will not inherit the kingdom of God and this includes the sexually immoral, adulterers, and homosexuals. These desires and acts are manifestations of rebellion against God's will and design. Do not be deceived, thinking that everyone will inherit a place in God's eternal kingdom and glory. The Corinthians were to therefore turn away from these sins and to discipline those who refused to repent and continued in these ways (1 Cor. 5:11).
1 Corinthians 6:11 goes on to give hope for sinners and to inspire gratitude and humility in the hearts of believers by saying, "And such were some of you. But you were washed, you were sanctified, you were justified in the name of the Lord Jesus Christ and by the Spirit of our God." Being justified (accounted righteous) and sanctified (cleansed from defilement and made holy) are benefits purchased by Christ, to be obtained in His name, and they are applied to us by the Spirit of our God who unites us to Christ through faith. Therefore, believers are not "the unrighteous." The blood-washed saints will "inherit the kingdom."
1 Corinthians 6:12-20 then goes on to apply this new identity to the present life of the Christian. It says that your body is a body part of Christ, a temple of the Holy Spirit, and a ransomed possession of Christ. Therefore, do not unite Christ to immorality! Do not defile the temple with sin! Do not spurn the great cost of your redemption by using Christ's possession against His will!
Therefore, flee sexual immorality! Make your body holy, consecrated, and governed by Christ. Make it an instrument of righteousness (see also Rom. 6:12-14).
1 Corinthians 7 goes on to describe how one flees sexual immorality. His basic principle is "because of the temptation to sexual immorality, each man should have his own wife and each woman her own husband" (1 Cor. 7:2). Marriage is a duty for most adults. The sexual desire is a natural desire, built into human nature, designed for a good end (Gen. 1:26-2:25), so direct it unto good rather than evil.
In 1 Corinthians 7:3-6, we find it is the duty of married people to not deprive each other sexually, except by mutual agreement for a limited time. Why? (1) Your bodies belong to each other - resulting in mutual rights and duties; and (2) for the prevention of immorality, minimizing Satan's ability to tempt you to sin.
In 1 Corinthians 7:7-8, there is an exception to this general rule of marriage. Singleness has some benefits if one has the gift for it (see 7:32-35). Singleness is not the gift. Continency - the ability to be single without distraction and passion - is the gift (see also Matt. 19:10-12). Those with this gift can still marry, but they do not need to, and they should consider whether they might serve the Lord better as single.
1 Corinthians 7:9 returns back to the normal duty to marry, and to this we might add 7:36-37 and 1 Timothy 5:11-14.
1 Corinthians 7:10-16 goes on to address the topic of divorce. It begins in verses 10-11 by summarizing what Jesus had taught on the subject in the case of marriage between two believers (Matt. 5:31-32, 19:1-9). They should not divorce (divorce in the case of sexual immorality was an exception taught by Jesus and assumed here by Paul), and if they do, they should remain unmarried or be reconciled. Verses 12-16 address the case of a believer's marriage with an unbeliever, a situation not addressed directly by the Lord while He was on earth. In this case, the believer should not leave - the unbelief of one's spouse does not defile the rest of the family (although this type of mixed marriage should not be entered into, see 7:39). But if the unbeliever does not consent to continue their marriage and separates, then the believer must let them go. In such a divorce, they are free of their former marriage and can remarry.