The relegation matches started at Euro 2020 and the teams of Wales and Denmark were the first to meet.
Denmark has ridden a wave of emotion through the tournament since playmaker Christian Eriksen suffered cardiac arrest in the team’s opening group match and had to be resuscitated with a defibrillator.
Dolberg is former Ajax striker and the match was played at the club’s home stadium in Amsterdam.
Denmark coach Kasper Hjulmand gave Dolberg his first start of the tournament and he scored a goal in each half. Joakim Maele scored the third goal in the 88th minute and Martin Braithwaite added the fourth in injury time.
The Danes will play either the Netherlands or the Czech Republic in the quarterfinals in Baku on Saturday.
June 26, 19:00
European Championship 1/8 finals
Wales 0-4 Denmark