Revelation of John 13:8

8and all awho dwell on earth will worship it, everyone whose name has not been written before the foundation of the world in bthe book of life of cthe Lamb dwho was slain.

Revelation of John 17:8

8The beast that you saw ewas, and is not, and fis about to rise from gthe bottomless pit
Greek  the abyss
and igo to destruction. And jthe dwellers on earth whose names have not been written in kthe book of life from the foundation of the world will marvel to see the beast, because lit was and is not and is to come.
Copyright information for ESV