The Belgians can guarantee finishing first with a home win over Israel on Tuesday, with previous leaders Wales having been beaten 2-0 in Bosnia but qualifying after the Israelis lost.
"First of all I'm happy nobody's injured," Belgium manager Marc Wilmots told Belgian radio.
"Obviously, it's been some 33 years since we last qualified for two big tournaments in a row so we're quite happy, and I guess Belgium as well as the tournament's next door in France."
The Belgians were in control from the start with Radja Nainggolan opening the scoring in the 19th minute. Kevin De Bruyne made it 2-0 with a 20-metre free kick before the break.
The hosts clawed back a rare goal in the 51st minute when Ildefons Lima converted a penalty conceded by defender Jan Vertonghen, who had lost Andorra's Victor Moreira and could only stop him with an inclement nudge.
Belgium wrapped up the points and a place in France with a spot kick from Eden Hazard before Depoitre scored his first international goal.
Hazard could have made it 5-1 in the 78th with another penalty but this time Andorra's Ferran Pol made the save.
"We played a very complete and correct match, we circulated the ball around well against an adversary who defended with great rigour," added Wilmots.
"We remained patient and marked them at the right moment, created quite a few chances."
Belgium, quarter-finalists at the 2014 World Cup, will play at the European Championship for the first time since 2000 when they hosted the tournament with the Netherlands. The last time Belgium qualified for the finals was in 1984.