The yanglian yin 養廉銀 was an allowance paid as a surplus on the nominal salary (fenglu 俸祿) of state officials during the Qing period 清 (1644-1911). Because the nominal salary was relatively low, the danger of widespread corruption was imminent.
In 1724 the governor (xunfu 巡撫) of Shanxi, Nomin 諾珉, and the provincial administration commissioner (buzhengshi 布政使) of that province, Gao Chengling 高成齡 (1668-1748), suggested to the Yongzheng Emperor 雍正 (r. 1722-1735) to earmark part of the income from the transport-loss surcharge (haoxian 耗羨, huohao 火耗) for an additional payment (butie 補貼) towards state officials, a procedure known as haoxian guigong 耗羨歸公 "the surcharge is dedicated to the public". This surplus would help to "nourish incorruptibility" (yang liang 養廉), or at least somewhat prevent officials from enriching themselves at the cost of the people.
According to common principle, the procedure was first tested in Shanxi, before it was applied throughout the empire. The height of the yanglian payment differed from province to province, but in all cases constituted a multiple of the nominal salary, making the latter but a "pocket money". In provinces where the haoxian surcharge was relatively low, the income from the salt or tea tax served to pay the anti-corruption allowance of local officals. The total annual amount of the yanglian pay was 2.8 million liang. By average a governor-general (zongdu 總督) was granted between 13 and 30.000 liang, a governor between 10 and 15.000 liang, administration commissioners and surveillance commissioners (anchashi 按察使) between 3.000 and 9.000 liang, circuit intendants (daoyuan 道員) 2-6.000 liang, prefects (zhifu 知府) 800-6.500, and district magistrates (zhixian 知縣) 400-1.200 liang.
In case the government needed funds for certain projects it was possible that officials "donated" their yanglian pay (juan lian 捐廉, see contribution), and were in turn rewarded with a potential promotion or a brevet title.