NEW YORK — The 2016 presidential campaign has come with its fair share of punchlines, but for the first time Thursday the candidates asked for the laughs.

They didn't always get them, when even an event with a tradition of levity and lightheartedness, the annual Alfred E. Smith Memorial Foundation dinner, turned awkward. Boos came from the audience of 1,500.

Hillary Clinton and Donald Trump were expected to switch gears — from the knock-down punches traded at their third and final debate Wednesday to the political equivalent of a stand-up routine less than 24 hours later.

Both were keynote speakers at the Waldorf Astoria for the dinner, a Catholic white-tie charity gala where it is tradition that presidential candidates speak in a comedic tone.

Watch highlights of the jokes and barbs

The dinners over the years have had a comedy "roast" aspect to them, with candidates traditionally packing their speeches with self-deprecation and one-liners, a change from the bitter, personal rhetoric of the campaign.

Perhaps the loudest boos came when Trump, who spoke first, said WikiLeaks had shown Clinton had two different personas in public and private.

"Here she is tonight, in public, pretending not to hate Catholics," he said.

Clinton offered barbs questioning if Trump was a billionaire and said he had a set an example for youth, telling a fake anecdote about a third-grader who refused to hand in his homework because it was under audit.

She mocked the flattering language from Trump's physician praising the Republican nominee's health.

"But Donald really is healthy as a horse ... you know, the one Vladimir Putin rides around with," she said.

Before their speeches, the candidates ate dinner at the dais separated only by New York Cardinal Timothy Dolan.

Trump's most memorable lines:

-- "Michelle Obama gives a speech and everyone loves it; it's fantastic. They think she's absolutely great. My wife Melania gives the exact same speech and people get on her case."
-- "Here she is in public tonight pretending not to hate Catholics."
-- “Hillary isn't laughing as much as the rest of us. That's because she knows the jokes, and all of the jokes were given to her in advance of the dinner by Donna Brazile,”
-- "Now I'm told Hillary went to confession before tonight's event, but the priest was having a hard time when he asked her about her sins and she said she couldn't remember 39 times."
-- "Hillary is so corrupt, she got kicked off the Watergate Commission. How corrupt do you have to be to get kicked off the Watergate Commission? Pretty corrupt."

Clinton's most memorable lines:

-- "I'm not eligible for sainthood, but getting through these three debates with Donald has to count as a miracle. So I guess I'm up against the highest, hardest, stained-glass ceiling."
-- "I just want to put you all in a basket of adorables."
-- "Donald, after listening to your speech, I will also enjoy listening to Mike Pence deny that you ever gave it."
-- "People look at the Statue of Liberty and they see a proud symbol of our history as a nation of immigrants, a beacon of hope for people around the world. Donald looks at the Statue of Liberty and sees a 4."
-- "Let's come together, remember what unites us, and just rip on Ted Cruz."

Cardinal Timothy Dolan poses with Donald Trump and Hillary Clinton the annual Alfred E. Smith Memorial Foundation Dinner at the Waldorf Astoria October 20, 2016 in New York City. (Photo by Daniel Goodrich/Archdiocese of New York via Getty Images)

Cardinal Timothy Dolan, who sat in between Clinton and Trump at last night's dinner, appeared on "Today" and described some touching moments that weren't caught on microphone.

"After the little prayer, Mr. Trump turned to Secretary Clinton and said, 'You are one tough and talented woman,' Dolan said. Clinton then returned the compliment. 'She said to him, "Donald, whatever happens we need to work together afterward,"' Dolan said."

Since 1960, at least one of the major party nominees has appeared at nearly every election-year dinner, which is traditionally the last time the nominees share a stage before voters go to the polls.

Four years ago, President Obama and Mitt Romney set aside their differences to trade (mostly) warm jokes. Romney, scanning the well-heeled crowd in the gilded Waldorf-Astoria ballroom, joked that the event’s white-tie attire finally gave him a chance to publicly don what “Ann and I wear around the house.” Obama, meanwhile, used his speech that year to look ahead to an upcoming debate on foreign policy, previewing his argument by saying, “Spoiler alert: We got bin Laden."