Gold was present in the deeps of Arda since its creation by Eru. It was most likely discovered by the Vala Aulë, the great smith, for he was the first to make use of it. Afterwards, gold was used by all speaking peoples of Arda, particularly the Dwarves and the Ñoldor.
It was used as currency and jewelry, among other things. It was to be found all over Arda, particularly in mountainous places where the Dwarves lived and worked. Many dragons coveted gold.
The great smiths of the Dwarves and Elves would forge gold in incredible works of skill and beauty, gilding great armors and weapons, as well as crafting amazing jewelry. Even the Vala prized and appreciated gold, working some of the greatest artifacts known.