Physicist: To answer this question definitively would require the destruction of at least a couple dozen other worlds. But failing that, guesswork:
The little things (people): In the short term (less than several million years) the biggest threat the Earth faces is people. We’ve already got the Holocene mass extinction going for us, now we’ve just got to step up our game and go for broke. Hey, Coalition of the Willing! I think I saw North Korea stealing your cup cakes. Also, it’s too cold in the winter. Couldn’t we burn another teraton of coal or something?
Boring, Regular Extinction: If we (Homo sapiens) follow the same fate as all of our predecessors and cousins (homo habilis, rudolfensis, georgicus, ergaster, erectus, cepranensis, antecessor, heidelbergensis, rhodesiensis, and neanderthalensis, for example), then it’s very likely that we’ll be extinct within the next 100,000 to 1,000,000 years. Statistically speaking anyway.
Total carbon re uptake: Over very large time scales the sun is getting brighter (along the lines of about 10% per billion years). Astrophysicist Brownlee and paleontologist Peter Ward have written a book espousing the idea that this gradual brightening will cause the Earth to heat up and the natural chemical processes that absorb CO2 from the air (and lock it away in sediment) will speed up.
They figure that inside of 500 million years there won’t be enough CO2 in the atmosphere to support plant life, and that would be the end of complex life. Although life has been around for at least 3.5 billion years, the interesting stuff (animals) have only been around for about 500 million years. So if Brownlee and Ward are right, we’re only about halfway done (not nearing the end).
It may seem strange to talk about the loss of CO2 being the end of the world when we so often talk about the dangers of too much CO2. The difference is in the time scales. The spike of CO2 we worry about today is on the scale of centuries, while the long term absorption of CO2 is on a time scale a million times larger (unnoticeable in the short term).
Dynamo shutdown: The Earth’s magnetic field is the result of iron rich (electrically conductive) stuff flowing around in the Earth’s core. The currents are driven by radioactive heating which causes convection, specifically the decay of radioactive potassium, uranium, and thorium. The half-lives of these materials are 1.25 billion, 4.5 billion, and 14 billion years respectively, so most of the original fuel has already been used up.
The exact nature of magnetic dynamos is not terribly well known, and is still an active area or research. We don’t know for certain what the minimum energy input is needed to keep the damn thing running. We do know that it’s certainly possible for a planetary magnetic dynamo to shut down (Mars’ shut down at least a couple billion years ago). If our dynamo shuts down, then our magnetic field will vanish and (in fairly short order) the atmosphere will be stripped away by solar wind, as happened on Mars.
Never-ending Summer: The increase in the Sun’s output will make it too hot for liquid water on Earth in about 1 billion years. With the oceans boiled away the pressure everywhere on Earth will be about the same as the pressure on the ocean floor. The difference between Venus and Earth will be academic. No matter what else happens before then, this will be the end of life on Earth.
SPF 5,000,000,000,000,000: Somewhere around 5 to 7 billion years from now the Sun will start to run out of fuel. Ironically this will actually make the core hotter as it collapses in on itself. The top layers will fluff up and (probably) envelope all the inner planets, including Earth. For obvious reasons this is called the “red giant” phase of the Sun’s life. The solar system will eventually settle down with the gas giants still in place, the inner solar system missing, a white dwarf star where the Sun used to be, and the trans-neptunian stuff completely unaffected.
Lights out: If by “end of the world” you mean “end of the universe”, then a good end of everything is the end of the age of stars. The universe started out made up of about 75% hydrogen, but today is only about 70% hydrogen. Stars are almost completely powered by hydrogen fusion, so assuming that the consumption of the universe’s hydrogen stays constant (which isn’t a particularly good assumption), then there will be almost no stars left in 250 to 300 billion years.
The big rip: Not only is the universe expanding, but the speed of that expansion is increasing. The expansion is a little hard to picture because the expansion isn’t about things moving away from each other in space, it’s about the space in between things actually expanding. Right now the effect is small enough that it can only be seen on huge, inter-galactic, scales. But eventually the expansion with be so rapid that the space between the planets and their stars will increase so fast that the planets will be pulled into open space, and not long after than (as in a couple of months or so) the space between atoms will increase so fast that everything will be completely torn apart and atomized. This is called the “big rip”. Some estimates put the big rip about 20 billion years out, and some say it won’t happen at all.