Goya was born in Fuendetodos, Aragón, Spain, in 1746 to José Benito de Goya y Franque and Gracia de Lucientes y Salvador. He spent his childhood in Fuendetodos, where his family lived in a house bearing the family crest of his mother. His father earned his living as a gilder. About 1749, the family bought a house in the city of Zaragoza and some years later moved into it. Goya may have attended school at Escuelas Pias, where he formed a close friendship with Martin Zapater. Their correspondence from the 1770s to the 1790s is a valuable source for understanding Goya's early career at the court of Madrid.
At age 14, he entered apprenticeship with the painter José Luzán. He later moved to Madrid where he studied with Anton Raphael Mengs, a painter who was popular with Spanish royalty. He clashed with his master, and his examinations were unsatisfactory. Goya submitted entries for the Royal Academy of Fine Art in 1763 and 1766, but was denied entrance.
He then journeyed to Rome, where in 1771 he won second prize in a painting competition organized by the City of Parma. Later that year, he returned to Zaragoza and painted parts of the cupolas of the Basilica of the Pillar (including Adoration of the Name of God), a cycle of frescoes in the monastic church of the Charterhouse of Aula Dei, and the frescoes of the Sobradiel Palace. He studied with Francisco Bayeu y Subías and his painting began to show signs of the delicate tonalities for which he became famous.