Džeko's first appearance for his home country came with the Bosnia and Herzegovina national under-19 football team. He was also part of the under-21 team who played in the play-offs for UEFA European Under-21 Championship hosted by the Netherlands in 2007. Bosnia's first challenges in this competition were Armenia under-21 and Norway under-21. They beat Armenia 3–2 and tied with Norway 1–1, qualifying for the playoff against the Czech Republic under-21. In the first leg, Bosnia lost 2–1; in the second, the game ended in a 1–1 draw. Džeko scored one goal in the tournament.