Throughout his career, Andrew Sean Greer has written serious novels. “The Confessions of Max Tivoli,” his 2004 breakthrough, imagined a man, born old, who ages backward. In 2013’s “The Impossible Lives of Greta Wells,” his title character lives three versions of her life.

Now Greer has done something completely unexpected: He’s written a comic novel.

“Less” (Little Brown, $26, 272 pages) is so funny, it’s hard to believe it started as a drama — “a sort of poignant, wistful novel,” says the author, “about a middle-aged man who walks across San Francisco, reflecting on his life and loves.”

Rather than abandon the book, Greer flipped it, making his protagonist a Job-like character for whom, if anything can go wrong, it probably will. The result is a witty, brilliant tour de force — Greer’s finest work to date.

Talking about “Less” recently over iced tea, Greer, 46, said the story took its own path. “The hardest part for me is finding a way into the novel,” he said. “It can take a year. Once I find it, it feels inevitable. With this one, it took a while — then it was the only way to write it.”

Like our Facebook page for more conversation and news coverage from the Bay Area and beyond.

“Less” is the story of Arthur Less, a gay San Francisco novelist who is experiencing a midlife crisis. His 50th birthday is fast approaching. His literary reputation is fading. Worst of all, his younger boyfriend has decided to marry someone else — and Arthur is invited to the wedding.

Rather than endure the humiliation, Arthur accepts a stack of invitations to author events around the world. As he travels to readings, festivals and awards ceremonies in New York, Mexico, Paris, Berlin, Morocco, India and Japan, the mishaps pile up like literary rejects in a second-hand bookstore.

Surprisingly, Greer says that travel wasn’t part of the original story. “But I was traveling, and I was alone, so I just took notes,” he says. “When I’d come back, I’d tell my friends, and it was funny. It was so much fun, I got rid of the main story and invented a new plot.”

It’s not that Greer didn’t feel sympathy for Arthur. “Every writer is an outsider,” says the author, who lives in San Francisco’s Lower Haight with his husband, a change management consultant in the tech industry. “But being midlist and midlife is hard. No one can celebrate you for being a debut writer or as a comeback — a rediscovered elderly writer.”

Writing a comedy offered an irresistible opportunity to skewer some of the absurd extremes of contemporary literature — as in Arthur’s humiliating appearance on a Mexican panel devoted to his former lover, poet Robert Brownburn of the celebrated Russian River school; or his encounter with fantasy writer H.H.H. Mandern, the tin-eared, immensely popular author of “space operettas.” There’s a sandstorm in Morocco, a wardrobe malfunction in India and an awards ceremony in Italy, where the jury is made up of 12 high school students.

Like Arthur, Greer has traveled widely — which gave him plenty of background for “Less.”

“I had two rules,” he said. “I could not put in any details that I did not see myself and write in my notebook. I didn’t want to write a fantasy of a foreign country; India isn’t all elephants and saffron robes, and Berlin isn’t lederhosen and polkas. The second rule was that the joke was on Arthur. He’s the one who’s always out of place.”

Greer’s sense of humor is apparent on every page, but “Less” has an emotional depth absent in many comic novels; in the end, the novel is a sublime meditation on second chances. He cites influences such as Nabokov’s “Pnin,” Updike’s “Bech” books and Roth’s Zuckerman novels. “Less” is dedicated to Daniel Handler, another San Francisco writer of rare comic gifts. The two men have been friends for years, and Greer says that Handler read multiple drafts of “Less.” “His best advice was in the last chapter,” says Greer. “He said ‘shorten it.’ ” (Which Greer did.)

Greer still seems a little surprised that “Less” is a hit, but he’s glad he decided to go with his impulse to turn a serious novel into comic one. I ask if he plans to return to Arthur in a future book. “I don’t think I’m finished with him,” he says. “This is my favorite book that I’ve written. He was so much fun to write.”

Contact Georgia Rowe at growe@pacbell.net.

Read the opening page of ‘Less’

… at www.mercurynews.com/books

FROM PAGE ONE

“Less at First

“From where I sit, the story of Arthur Less is not so bad. Look at him: seated primly on the note lobby’s plush round sofa, blue suit and white shirt, legs knee-crossed so that one polished loafer hangs free of its heel. The pose of a young man, His slim shadow is, in fact, still that of his younger self, but at nearly fifty he his like those bronze statues in public parks that, despite one lucky knee rubbed raw by schoolchildren, discolor beautifully until they match the trees. So has Arthur Less, once pink and gold with youth, faded like the sofa he sits on, tapping one finger on his knee and staring at the grandfather clock. The long patrician nose perennially burned by the sun (even in cloudy New York October).The washed-out blond hair too long on the top, too short on the sides — portrait of his grandfather. Those same watery blue eyes. Listen: you might hear anxiety ticking, ticking, ticking away as he stares at that clock, which is unfortunately not ticking itself. It stopped fifteen years ago. Arthur Less is not aware of this; he still believes, at his ripe age, that escorts for literary events arrive on time and bellboys reliably wind the lobby clocks. He wears no watch; his faith is fast. It is mere coincidence that the clock stopped at half past six, almost exactly the hour when he is to be taken to tonight’s event. The poor man does not know it, but the time is already quarter to seven.”

Like our Facebook page for more conversation and news coverage from the Bay Area and beyond.

John Travolta’s mob movie flop “Gotti” and President Donald Trump were nominated on Monday for the Razzie Awards for the worst films of 2018 after a year that organizers called full of disasters - both on and off screen.