Where do I go when I die? Does my body go to the grave and my spirit or soul go immediately to heaven? What is Ecclesiastes 3:18-21 talking about? Are souls immortal?
A portion of your questions was previously answered in "What happens to you when you die?" Rather than repeating the material here, I ask you to read that answer and I will focus on the remaining questions here.
"I said in my heart, "Concerning the condition of the sons of men, God tests them, that they may see that they themselves are like animals." For what happens to the sons of men also happens to animals; one thing befalls them: as one dies, so dies the other. Surely, they all have one breath; man has no advantage over animals, for all is vanity. All go to one place: all are from the dust, and all return to dust. Who knows the spirit of the sons of men, which goes upward, and the spirit of the animal, which goes down to the earth? So I perceived that nothing is better than that a man should rejoice in his own works, for that is his heritage. For who can bring him to see what will happen after him?" (Ecclesiastes 7:18-22).
The writer of Ecclesiastes, Solomon, notes that two things that happens to men and animals. One of those things is the same ("All are from the dust, and all return to dust") and one is different ("the spirit of the sons of men, which goes upward, and the spirit of the animal, which goes down to the earth"). A little later in the book, Solomon again states the same fact concerning man. "Remember your Creator before the silver cord is loosed, Or the golden bowl is broken, Or the pitcher shattered at the fountain, Or the wheel broken at the well. Then the dust will return to the earth as it was, And the spirit will return to God who gave it" (Ecclesiastes 12:6-7).
Why did God place men in a world where they die? Solomon says that it is a test or a trial. One of the things we are to learn is that we are, in some ways, like the animals -- we physically die. Paul commented, "Therefore, just as through one man sin entered the world, and death through sin, and thus death spread to all men, because all sinned" (Romans 5:12). Or as the Hebrew writer points out, "And as it is appointed for men to die once, but after this the judgment" (Hebrews 9:27). In this sense, man has no advantage over the animals. The fact that he has a spirit from God doesn't make him better than an animal in this regard. In other words, the fact that we must die ought to be a humbling thought to every man. We are in this state because of sin; Adam openned the door to sin and death and we keep the door open each time we sin.
The sons of Korah explains this in Psalm 49: "Hear this, all peoples; Give ear, all inhabitants of the world, Both low and high, Rich and poor together. My mouth will speak wisdom, And the meditation of my heart will be understanding. I will incline my ear to a proverb; I will express my riddle on the harp. Why should I fear in days of adversity, When the iniquity of my foes surrounds me, Even those who trust in their wealth And boast in the abundance of their riches? No man can by any means redeem his brother Or give to God a ransom for him-- For the redemption of his soul is costly, And he should cease trying forever-- That he should live on eternally, That he should not undergo decay. For he sees that even wise men die; The stupid and the senseless alike perish And leave their wealth to others. Their inner thought is that their houses are forever And their dwelling places to all generations; They have called their lands after their own names. But man in his pomp will not endure; He is like the beasts that perish. This is the way of those who are foolish, And of those after them who approve their words. Selah. As sheep they are appointed for Sheol; Death shall be their shepherd; And the upright shall rule over them in the morning, And their form shall be for Sheol to consume So that they have no habitation. But God will redeem my soul from the power of Sheol, For He will receive me. Selah. Do not be afraid when a man becomes rich, When the glory of his house is increased; For when he dies he will carry nothing away; His glory will not descend after him. Though while he lives he congratulates himself--And though men praise you when you do well for yourself-- He shall go to the generation of his fathers; They will never see the light. Man in his pomp, yet without understanding, Is like the beasts that perish." (Psalms 49:1-20)
Man often thinks of him was something great, especially those who gain great wealth. But as the sons of Korah note, all the wealth in the world cannot buy the salvation of a single soul. Nor can wealth purchase eternal life. Oh, we often act like we will live forever, but everyone dies. It is what happens to man after death that is important.
Which brings us to the last point of Solomon. If we focus solely on the physical body, man is no different from an animal, but if we focus on the spirit there is a huge difference. Yet who comprehends this? There are far too many living life as if they are nothing more than animals. "But these speak evil of whatever they do not know; and whatever they know naturally, like brute beasts, in these things they corrupt themselves" (Jude 10).
Do we live on after death? Most certainly! "For this corruptible must put on incorruption, and this mortal must put on immortality. So when this corruptible has put on incorruption, and this mortal has put on immortality, then shall be brought to pass the saying that is written: "Death is swallowed up in victory."" (I Corinthians 15:53-54). Or as Paul also said, "For we know that if our earthly house, this tent, is destroyed, we have a building from God, a house not made with hands, eternal in the heavens. For in this we groan, earnestly desiring to be clothed with our habitation which is from heaven, if indeed, having been clothed, we shall not be found naked. For we who are in this tent groan, being burdened, not because we want to be unclothed, but further clothed, that mortality may be swallowed up by life. Now He who has prepared us for this very thing is God, who also has given us the Spirit as a guarantee. So we are always confident, knowing that while we are at home in the body we are absent from the Lord. For we walk by faith, not by sight. We are confident, yes, well pleased rather to be absent from the body and to be present with the Lord.Therefore we make it our aim, whether present or absent, to be well pleasing to Him. For we must all appear before the judgment seat of Christ, that each one may receive the things done in the body, according to what he has done, whether good or bad. Knowing, therefore, the terror of the Lord, we persuade men; but we are well known to God, and I also trust are well known in your consciences" (II Corinthians 5:1-11). Notice carefully that Paul said that the building we receive after this one dies is eternal. It is true for both the righteous and the wicked. "And these will go away into everlasting punishment, but the righteous into eternal life" (Matthew 25:46). Knowing that God keeps His promises, knowing that He promised eternal punishment for the wicked, ought we not be eager to make sure that we, our familes, our friends, and our neighbors all spend eternity in Heaven and not Hell?