Objectives To assess the availability and affordability of oral anti-diabetic medicines in Shaanxi Province, Western China. Methods In 2015, the prices and availability of 8 anti-diabetic medicines covering 31 different dosage forms and strengths were collected in six cities of Shaanxi Province. A total of 72 public hospitals and 72 private pharmacies were sampled, using a modified methodology developed by the World Health Organization (WHO) and Health Action International (HAI). Medicine prices were compared with international reference prices to obtain a median price ratio. For urban residents, affordability was assessed as the lowest-paid unskilled government workers to purchase cost of standard treatment in days' wages; for rural residents, days' net income was used. Results The mean availabilities of originator brands (OBs) and generics were 34.3% and 28.7% in public hospitals, and 44.1% and 64.4% in the private pharmacies. OBs and the lowest priced generics (LPGs) were procured at 12.38 and 4.52 times the international reference price in public hospitals, and 10.26 and 2.81 times the international reference prices in private pharmacies. Treatments with OBs were unaffordable even for urban residents. The affordability of the LPGs was good, except for acarbose, repaglinide and pioglitazone.