The doctor who tried to warn the world about coronavirus in December and was silenced by Chinese authorities has died.

Li Wenliang, 34, was an opthamologist working at Wuhan Central Hospital in December when he saw test results that showed that seven patients from a local market had been diagnosed with an unknown illness that looked a lot like SARS, the virus that killed 774 people across Asia in 2003.

He tried to raise the alarm among friends in a private messaging group in late December. The police ordered him to keep quiet. He went back to work on the front lines fighting the virus and, like tens of thousands of others, ended up contracting it himself.

On Thursday, he died.

Li is survived by his parents, both of whom are infected, and his wife, who is pregnant with their second child, and has also contracted coronavirus, according to local media reports.

On December 30, Li sent a message to his medical school alumni group on the popular Chinese messaging app WeChat telling them to privately warn their families. Instead, a screenshot of his warning was posted online without his name being blurred out, and it went viral.

Within hours, Li was summoned by officials at his hospital to explain how he knew about the tests, and days later he was ordered to appear at his local police station, where he was warned to stop spreading “rumors” and forced to sign a statement acknowledging his “misdemeanor” and promising not to commit further “unlawful acts.”

"We solemnly warn you: If you keep being stubborn, with such impertinence, and continue this illegal activity, you will be brought to justice — is that understood?” the statement said, the BBC reports.

On Jan. 10, Li unwittingly treated a patient with coronavirus. Two days later the 34-year-old began coughing and was admitted to hospital. His condition deteriorated and days later he was admitted to intensive care. He was diagnosed with the coronavirus on Feb. 1.

In his final post on Weibo before he died, on Jan. 30, Li asked: “I was wondering why (the government's) official notices were still saying there was no human-to-human transmission, and there were no healthcare workers infected.”

Wuhan Central Hospital announced Li's passing on its official Weibo account: ”In the fight against the pneumonia epidemic of the new coronavirus infection, our hospital’s ophthalmologist Li Wenliang was unfortunately infected. He passed away after all the efforts we’ve taken to resuscitate him. We deeply mourn his passing.”

At the time Li raised the alarm in late December, there were very few reports about the outbreak, and the authorities were eager to keep it that way. The police announced on Jan. 1 that it had "taken legal measures” against eight people who had recently “published and shared rumors online" about the pneumonia-like illness and "caused adverse impacts on society.”

"The internet is not land beyond the law ... Any unlawful acts of fabricating, spreading rumors, and disturbing the social order will be punished by police according to the law, with zero tolerance."

The outbreak has so far killed at least 566 people and infected more than 28,000. Experts believe the real figures and order of magnitudes higher.