Hanyin County () is a county in the south of Shaanxi province, China. It is under the administration of the prefecture-level city of Ankang.
Hanyin was established as early as the Qin dynasty and then known as Xicheng County. In 757 AD it became Hanyin.
As of 2019, Hanyin County is divided to 10 towns.
Hanying is served by the YangpingguanâÂÂAnkang Railway. Major highways include China National Highway 316 as well as the G7011 ShiyanâÂÂTianshui Expressway.