The future of humanity is bound to the future of science, and our prospects hinge on how successfully we harness technological advances to address the challenges to our collective future. If we are to use science to solve our problems while avoiding its dystopian risks, we must think rationally, globally, collectively, and optimistically about the long-term future. Advances in biotechnology, cybertechnology, robotics, and artificial intelligence--if pursued and applied wisely--could empower us to boost the developing and developed world and overcome the threats humanity faces on Earth, from climate change to nuclear war. At the same time, further advances in space science will allow humans to explore the solar system and beyond with robots and AI. But there is no "Plan B" for Earth--no viable alternative within reach if we do not care for our home planet.