Among Christians the concept of eternal rest for the deceased comes especially from several statements in the New Testament, but it does also draw on Old Testament themes and passages.
Old Testament themes
The very first mention of "rest" in the Bible occurs on the seventh day of creation:
Thus the heavens and the earth were finished, and all their multitude. And on the seventh day God finished the work that he had done, and he rested on the seventh day from all the work that he had done. So God blessed the seventh day and hallowed it, because on it God rested from all the work that he had done in creation. (Genesis 2:1–3, italics added)
This passage sets the tone throughout the Bible for the idea of rest after labors.
Though there is very little in the Old Testament about any afterlife, the concept of the deceased being "at rest" is present there.
The Old Testament commonly speaks of death as "sleeping with one's ancestors." Here are just a few examples:
Then David slept with his ancestors, and was buried in the city of David. (1 Kings 2:10)
Solomon slept with his ancestors and was buried in the city of his father David; and his son Rehoboam succeeded him. (1 Kings 11:43)
The time that Jeroboam reigned was twenty-two years; then he slept with his ancestors, and his son Nadab succeeded him. (1 Kings 14:20)
Rehoboam slept with his ancestors and was buried with his ancestors in the city of David. His mother’s name was Naamah the Ammonite. His son Abijam succeeded him. (1 Kings 14:31)
And Job poetically speaks of the dead as being at rest:
Why did I not die at birth,
come forth from the womb and expire?
Why were there knees to receive me,
or breasts for me to suck?
Now I would be lying down and quiet;
I would be asleep; then I would be at rest
with kings and counselors of the earth
who rebuild ruins for themselves,
or with princes who have gold,
who fill their houses with silver.
Or why was I not buried like a stillborn child,
like an infant that never sees the light?
There the wicked cease from troubling,
and there the weary are at rest.
There the prisoners are at ease together;
they do not hear the voice of the taskmaster.
The small and the great are there,
and the slaves are free from their masters.
And the Psalms speak of the faithless and disobedient Israelites whom God had miraculously brought out of slavery from Egypt not entering into God's rest:
O that today you would listen to his voice!
Do not harden your hearts, as at Meribah,
as on the day at Massah in the wilderness,
when your ancestors tested me,
and put me to the proof, though they had seen my work.
For forty years I loathed that generation
and said, "They are a people whose hearts go astray,
and they do not regard my ways."
Therefore in my anger I swore,
"They shall not enter my rest."
Though the original meaning of "not entering my rest" here was not being allowed to enter the Holy Land, where the Children of Israel would settle down and be at "rest" from their long wanderings, in the New Testament this passage is given a deeper meaning related to God's promised spiritual rest (see the quotation from Hebrews just below).
New Testament themes
The New Testament also speaks of those who have died having followed the Lord during their lifetimes as being "at rest."
The Letter to the Hebrews ties together Old Testament themes of rest with the inner rest that the faithful will experience:
Therefore, while the promise of entering his rest is still open, let us take care that none of you should seem to have failed to reach it. For indeed the good news came to us just as to them; but the message they heard did not benefit them, because they were not united by faith with those who listened. For we who have believed enter that rest, just as God has said,
"As in my anger I swore,
'They shall not enter my rest.'"
though his works were finished at the foundation of the world. For in one place it speaks about the seventh day as follows, "And God rested on the seventh day from all his works." And again in this place it says, "They shall not enter my rest." Since therefore it remains open for some to enter it, and those who formerly received the good news failed to enter because of disobedience, again he sets a certain day—"today"—saying through David much later, in the words already quoted,
"Today, if you hear his voice,
do not harden your hearts."
For if Joshua had given them rest, God would not speak later about another day. So then, a sabbath rest still remains for the people of God; for those who enter God’s rest also cease from their labors as God did from his. Let us therefore make every effort to enter that rest, so that no one may fall through such disobedience as theirs.
Indeed, the word of God is living and active, sharper than any two-edged sword, piercing until it divides soul from spirit, joints from marrow; it is able to judge the thoughts and intentions of the heart. And before him no creature is hidden, but all are naked and laid bare to the eyes of the one to whom we must render an account. (Hebrews 4:1–13)
Though this passage does not explicitly connect God's promised rest with death, the theme of judgment and of rendering accounts in the final two verses suggests a connection with God's eternal judgment of human souls after death.
That connection is made explicit in the Book of Revelation:
And I heard a voice from heaven saying, "Write this: Blessed are the dead who from now on die in the Lord." "Yes," says the Spirit, "they will rest from their labors, for their deeds follow them." (Revelation 13:14)
And one more reference, from the Gospel of Luke, in which Jesus is speaking of entering through the narrow door (Luke 13:22–30), here in a very literal translation:
and they shall come from east and west, and from north and south, and shall recline in the reign of God (Luke 13:19, Young's Literal Translation, italics added)
The Greek word for "recline" here, commonly translated "sit down," is ἀνακλίνω, (anaklinō), "to lay down, to bid recline." This refers to the ancient custom of reclining on couches to eat. Luke's imagery is of people who have entered the kingdom of God reclining, or resting, at the metaphorical banquet of God's kingdom.
These are some of the Bible passages on which the idea that the deceased have "entered into eternal rest" is based.