Ron Klain, the former Ebola czar under President Barack Obama, gave the Trump administration a failing grade Friday for its response to the coronavirus.

"Fairly I'd have to say it's an 'F,'" Klain said on CNBC's "Squawk on the Street."

President Donald Trump has touted his administration's actions on the coronavirus, often pointing to a Jan. 31 order restricting travel from China as evidence of its early, aggressive approach to limiting the spread.

But Klain pushed back on the notion that imposing severe travel restrictions was an adequate response, arguing it was only a "partial ban."

Klain said he did believe the Trump administration's late January restrictions "bought us some time" to prepare for the disease's global spread. "But we squandered that time," he said.

"What we're living with now in this country, the virus was created by nature, but the failed response was created by decisions we made," Klain said.

Klain, an attorney who oversaw the Obama administration's response to the Ebola epidemic in West Africa from 2014 to 2015, argued that other countries responded more adequately than the U.S. and therefore better contained the spread. He said South Korea and Singapore are examples of nations that responded well.

"If you look at the countries that have been most successful, they used the time they got, from the time they knew the virus was coming until the time it came, to ramp up testing, to ramp up hospitals, to ramp up gear, to ramp up [personal protective equipment]," he said.

"We didn't do any of those things. We sat around and spent those two months sitting around saying, 'It's not going to be here. Fifteen cases, it's going to go to zero, so on, so forth," he said.

Klain said the administration's response to the coronavirus has improved recently.

"But we're going to pay a huge price for squandering January, squandering February, squandering even a little bit of March," he said.

White House spokesman Judd Deere pushed back against Klain's comments, noting the Obama administration received its share of criticism for how it handled the Ebola outbreak. Judd wrote that it was "ironic" for Klain to play "Monday-morning-quarterback" over how the Trump administration has responded to COVID-19.

In recent weeks, the Trump administration has taken steps to increase U.S. testing capacity and speed up vaccine development, issued strict guidelines to restrict large gatherings, which helps to limit person-to-person transmission, and championed relief measures to soften the economic damage created by the disease.

Those efforts include supporting cash payments to Americans, as well as moving the tax deadline from April 15 to July 15.

"As the President said last week, we are using the full power of the federal government and working in partnership with the private sector for this all-of-America effort, and he has no higher priority than the health and safety of the country," Deere wrote in an email.

Trump, who also restricted travel from Europe, said Tuesday he had believed the coronavirus was a pandemic "long before it was called a pandemic."

But in Jan. 22 interview on CNBC, Trump claimed the virus was "totally under control" and said he was not worried about the disease becoming a pandemic.

The first person in the U.S. who was confirmed to have the virus was a traveler from China. The positive diagnosis came on Jan. 21, one day before Trump's comments to CNBC.

COVID-19, the disease caused by the virus, has sickened at least 247,000 people across the globe since it originated in China in late December.

There are more than 14,000 confirmed cases of COVID-19 in the U.S. as of Friday morning, according to Johns Hopkins University data. More than 200 people have died.