The Hammers suffered a gut-wrenching 2-1 defeat against United in the Premier League on Sunday when David De Gea saved Mark Noble's stoppage-time penalty after Jesse Lingard's late winner.
But David Moyes' men got a measure of revenge three days later as Manuel Lanzini's first-half goal dumped United out in the third round.
Solskjaer made 11 changes and Moyes opted for 10 alterations, with West Ham's understudies making the most of their moment in the spotlight.
Ryan Fredericks ghosted past Alex Telles and cut back for Lanzini to sweep past United goalkeeper Dean Henderson in the ninth minute.
That was enough for Moyes to secure a first win over United since they sacked the Scot after less than a season in charge in 2014.
It was also West Ham's first victory at Old Trafford since 2007, earning them a home tie against holders Manchester City in the last 16.
Solskjaer criticised his team's tentative opening, saying: "A slow start again and that needs addressing.
"I've never actually won this tournament, so that hunt will keep going.
"But we have to make the decisions to have the squad up to speed for the rest of the season. Sometimes you have to take risks."
At Stamford Bridge, Chelsea won 4-3 on penalties after a 1-1 draw against Aston Villa.
Much-maligned German forward Timo Werner headed Chelsea into the lead in the 54th minute, finishing off Reece James' cross for his first goal in 11 games.
With Villa fan, Prince William watching from the stands, 19-year-old striker Cameron Archer equalised in the 64th minute with a close-range header from Matty Cash's cross.
James scored Chelsea's winning penalty in the shoot-out after Ashley Young and Marvelous Nakamba missed for Villa.