(Tested) I've got good news and bad news. The good news is that the Earth won't be destroyed by the inevitable heat death of the universe. The bad news is that the planet will be wiped out long before that, between 1.5 billion and 2.25 billion years from now, according to a new study by Andrew Rushby recently published in Astrobiology.
You see, when our Sun starts running out of hydrogen fuel, it will expand until it swallows Mercury and Venus, and potentially even expands into our orbit. Obviously, this means bad things for anything left on Earth. Even if the Sun doesn't grow large enough to reach Earth's orbit, you don't want to hang around waiting for the oceans to boil away and the atmosphere to burst into flame. Trust me, you'll have a bad time.