Back in the late 1800s, the best graphite for making pencils was in China. The western pencil manufacturers wanted their customers to associate their product with the quality so they made them the color of Chinese royalty which is yellow.