Aqua regia works to dissolve gold, even though neither constituent acid will do so alone because, in combination, each acid performs a different task. Nitric acid is a powerful oxidizer, which will actually dissolve a tiny (virtually undetectable) amount of gold, forming gold ions. The hydrochloric acid provides a ready supply of chloride ions, which react with the latter, thus taking the gold out of the solution. This allows further oxidation of gold to take place, and so the gold is dissolved.
When the Nazis invaded Denmark, the Hungarian chemist George de Hevesy dissolved the gold Nobel Prizes of Max von Laue and James Franck into aqua regia and placed this reagent on a shelf in his laboratory at the Niels Bohr Institute. After the war, he returned to find the solution undisturbed and precipitated the gold out of the acid.
Note: Aqua regia should not be confused with acquaragia which is more commonly known as turpentine in English and is a completely different substance from aqua regia.