Get all your news in one place.
100's of premium titles.
One app.
Start reading
Cinemablend
Cinemablend
Entertainment
Dirk Libbey

The Story Behind Andy Weir Writing ‘The Perfect Ending’ For Project Hail Mary Before He Even Started The Book

Ryan Gosling in Project Hail Mary.

The following contains spoilers for the ending of Project Hail Mary.

Project Hail Mary has been the biggest theatrical hit from the 2026 movie schedule thus far, and not only from a box office standpoint. The Ryan Gosling-led film has received critical acclaim, and it continues to generate conversations amongst general audiences. One of the aspects of the film that’s seemingly being discussed at length is the way the story ends. In the mind of Andy Weir -- the author of the original novel -- the ending is "perfect" and, just recently, Weir opened up about knowing how the book would end before he actually started writing it.

Some writers admit that they don’t always know where a story is going when it begins or, of course, story plans can change over the course of the writing process. However, Andy Weir revealed that he knew where the main character of Project Hail Mary, middle school teacher Ryland Grace, would end up from the beginning, even if he wasn’t entirely clear on how he would get there. He told the New York Times

I knew that was going to be the end of the novel before I started writing the first page. I didn’t know all those steps that would get him there, but that’s how it was going to end. I think it’s a perfect ending for Ryland because he really liked being a teacher, and in the end, he gets to be a teacher and hang out with his best friend. And he’d be returning to an Earth where something like 75 years had passed since he left.

PHM ends with Ryland opts to save his alien friend, Rocky, and the Eridian race as a whole by turning his ship around and helping his ally return home. Ultimately, Grace opts to stay on the Eridians' planet, and he becomes a teacher there as well.

Phil Lord and Chris Miller, the directors of the film adaptation, clearly felt the ending was perfect as well. While Drew Goddard's screenplay makes a few minor changes and omissions from the book, the ending is largely intact in the movie.

While Project Hail Mary certainly has its share of fantastical elements, the science is as close to real as possible, which, if nothing else, means that relativity is an element that needs to be dealt with. In the film, it takes Gosling's Ryland years to get where he’s going, and it would take him just as long to return. This means that simply returning home wouldn’t necessarily be the “happy ending” that some might assume. Weir continued…

Everyone he knows back on Earth will have died. He doesn’t really have anything to go back to. But he’s got his best friend here. A job that he loves. Why would he leave?

“Why would he leave?” may actually turn out to be a very interesting question. There have reportedly been some discussions about a potential sequel to Project Hail Mary. While Andy Weir says he did hold some answers back from the book to potentially explore in a sequel, it’s far from clear where such a movie would actually go.

Nevertheless, even if an official follow-up never happens, I'd say that the story of Ryland Grace is fine where it is. For now, check out Project Hail Mary in theaters and make up your own mind about the ending.

Sign up to read this article
Read news from 100's of titles, curated specifically for you.
Already a member? Sign in here
Related Stories
Top stories on inkl right now
One subscription that gives you access to news from hundreds of sites
Already a member? Sign in here
Our Picks
Fourteen days free
Download the app
One app. One membership.
100+ trusted global sources.