A Chinese internet pioneer who once won Communist Party praise for using the Web to combat social ills was sentenced Monday to 12 years in prison — a further sign that the window for independent social activism in China has all but closed.

Huang Qi, 56, who spent nearly 20 years exposing local government malfeasance and brutality, and has already served eight years in prison, was found guilty by a court in southwestern China of “deliberately disclosing state secrets” and “illegally providing state secrets to foreign entities,” according to the court statement.

In addition to the prison term, he was deprived of political rights for four years and fined 20,000 yuan, or nearly $3,000.

It was one of the longest sentences given to a rights advocate in recent years and followed calls for clemency by human rights groups, foreign governments and the United Nations. In light of Mr. Huang’s chronic bad health, including high blood pressure as well as kidney and heart problems, the nongovernmental organization Reporters Without Borders called the 12-year term “equivalent to a death sentence.”