end of the world or of humans?
we know the world will end when out sun dies - which is fairly soon, a few million years - that isn't much in terms of space - as for humans, we won't be here long - at best a few thousand more years.
or if you listen to steven hawking - waaay less b/c we will kill each other off with some freak accident and hence he says we need to start trying to colonize space to ensure we stay around.