Ty Rattie scored for the Oilers (8-8-1), who have lost four games in a row. Cam Talbot allowed three goals on 15 shots and was replaced at 5:06 of the second period by Mikko Koskinen, who made 12 saves.
Rantanen scored 26 seconds into the game on the rebound of a MacKinnon shot to give Colorado a 1-0 lead.
"You can summarize the game in that first 25 seconds," Edmonton coach Todd McLellan said. "We didn't establish a directness to our attack, we turned the puck over in the neutral zone, and we got beat to a rebound. It puts us on our heels and gives a team that hasn't won confidence. They certainly took their game up after that and they chased it."
Soderberg made it 2-0 at 15:33 with a one-timer from the top of the left face-off circle off a pass from Barrie. It was Barrie's 200th NHL assist.
"It's big. You get one in the first shift, and you feel good about yourself," MacKinnon said. "Those are always good when you get one early. They don't come along very much, but when they do, it feels good. Up 2-0 in the first, a two-goal lead can be a tough one in hockey, but we had a good second period as well."
Alex Kerfoot gave the Avalanche a 3-0 lead at 5:06 of the second when Soderberg's shot from above the right circle caromed off the end boards to him to the right of the net.
"I think, obviously, for whatever reason we weren't ready to play tonight," Oilers forward Leon Draisaitl said. "I thought the third was a little better, but if you start like that, play like that for two periods, you're probably not going to beat a single team in this league."
Barrie scored his first goal of the season at 10:56 to make it 4-0, converting a pass from Rantanen from the side boards. It was his 62nd NHL goal, tying him with Rob Blake for third-most goals by a defenseman in Avalanche/Quebec Nordiques history (Sandis Ozolinsh, 72; John-Michael Liles, 68).
"That one is cool because Blake was my favorite defenseman growing up, and I wore No. 4 growing up because of him and I ended up playing for Colorado," Barrie said. "It's special."
Rattie scored at 9:20 of the third period to make it 4-1, redirecting a point shot from Adam Larsson.
"I really liked our commitment to defend," Avalanche coach Jared Bednar said. "Right out of our offensive zone, we weren't giving up any odd-man rushes. In the D zone, if we didn't win the battles down low below the goal line, we did a real good job collapsing with their wings and getting on their sticks in front of the net. And when they did get the puck back to the point, we were blocking shots."