The Denver Broncos have agreed to a trade to send Von Miller to the Los Angeles Rams, the eight-time Pro Bowl linebacker confirmed Monday.

The Rams will send the Broncos a second- and third-round pick in the 2022 NFL draft in exchange for Miller, sources told ESPN’s Adam Schefter.

The Broncos will also pay $9 million of Miller’s remaining $9.7 million base salary for the remaining nine games in the regular season, sources told Schefter.

An emotional Miller, sitting in the backseat of an SUV as he left the Broncos’ facility, told reporters he was surprised by the trade.

“It’s still kind of hard to put into words, it’s still kind of raw, but thank you, thank everybody and off to L.A.,” Miller said.

“It’s still hard, you can’t really put it into words,” Miller said. “Somebody told me once you want to make God laugh, then make plans. You’ve just got to keep going, keep taking it one day at a time, I’ve got a beautiful baby boy, had a lot of beautiful years here, lot of great memories, lot of great teammates, lot of great coaches, lot of great fans.”

In Los Angeles, Miller will join a 7-1 Rams team that is among the favorites to make a Super Bowl LVI run.

“Great team, I’ve been a huge fan of Aaron Donald for a long time. They got a great defense … I’m excited, always been a great teammate and I’m going to continue to do that,” Miller said, adding that he hopes to play on Sunday night when the Rams host the Tennessee Titans.

Over the offseason, the Rams completed a blockbuster trade for quarterback Matthew Stafford, whom the team believed could be the final addition needed to win a title and do so in their brand-new home at SoFi Stadium, where the next Super Bowl will be played.

Last month, with the trade deadline looming, Rams coach Sean McVay said he did not anticipate “any big splash moves, like maybe you’ve seen from us in the past.” But the fifth-year coach added, “I would never say never.”

Now Miller will provide needed reinforcement to a defense that has experienced a slight decline from last season’s top-ranked performance despite starring three-time NFL Defensive Player of the Year Donald and All-Pro cornerback Jalen Ramsey.

Miller, coming from coach Vic Fangio’s 3-4 scheme, should be a seamless fit with the Rams, whose system stems from Fangio’s, playing opposite of outside linebacker Leonard Floyd. And Miller will draw some attention away from Donald, who ranks 18th in the league with five sacks and has been double-teamed on 106 snaps this season, the fourth most in the NFL.

Miller, who hosted a Halloween party for his teammates and friends Sunday night, was at the team’s suburban Denver complex Monday morning to say his goodbyes to his coaches and teammates.

“Always have Super Bowl 50, seeing the pictures when I was walking out made me tear up,” Miller said. “We always got Super Bowl 50, always got Broncos Country and got to keep going.”

Miller, who was John Elway’s first draft pick (second overall) as the team’s top football decision-maker in 2011, was the longest-tenured Broncos player. He was in the final year of the six-year, $114.5 million contract he signed in late July 2016, six months after he had won the Super Bowl 50 MVP award. He is scheduled to be an unrestricted free agent following the season.

“When I said Broncos for life, I meant that, it will always be in my heart,” Miller said. “It was an honor and privilege to play here, John Elway picked me and it was life changing.”

Miller, 32, and kicker Brandon McManus were the only remaining players on the roster who played in Super Bowl 50 for the Broncos.

Fangio, who spoke just moments before the news of the Miller trade became public, said with the trade deadline approaching that “several” teams had called the Broncos about deals, but he gave no specifics.

With the team at 4-4, Fangio was then asked if he expressed any of his thoughts on what the team should do before Tuesday’s trade deadline to general manager George Paton.

“I told him to do whatever he needs to do and we’re going to coach and coach winning football with what we’ve got,” Fangio said. “I’ve not tried to influence him one way or another.”

Miller, who is the league’s active career sack leader with 110.5 (sacks became an official statistic in 1982), is one of the most decorated players in team history with eight Pro Bowl selections, three first-team All Pro selections and was chosen for the all-decade team for the 2010s by the Hall of Fame’s board of selectors.

Miller has a half-sack in the Broncos’ past five games after he had four in the team’s 3-0 start in September. Miller did not play Sunday against Washington because of a left ankle injury, and Fangio said after the game it was “not close” for Miller to be in the lineup.

When Miller was asked this past week about the approaching trade deadline and the team’s struggles in a four-game losing streak, he said:

“No, I can’t really control any of that. I’m here with these guys and I love all these guys — whether we lose or not. I can say that all these coaches, all these equipment managers, the media guys — everybody. I genuinely love these guys … While I’m here, while my key card still works, and while I’m a Denver Bronco, I’m going to continue to keep trying to fix it. I’m going to continue to try to do my part to put us back on the mountaintop. I’m going to continue to try to be the type of franchise that this franchise has been historically.”

This is the second trade between the Rams and Broncos before this year’s trade deadline. The Rams traded linebacker Kenny Young to the Broncos in a deal that involved a swap of draft picks last week. At the time, McVay said the decision to trade Young was “Financially driven.”

“Whether or not that means that any major big moves are imminent for us, that’s not something that I can really speak on right now,” McVay said.

The Rams are also anticipated to make another roster move after veteran receiver DeSean Jackson, who signed a one-year, $4.5 million deal that included $2.75 million guaranteed over the offseason, requested late last week to be traded.

McVay said after Sunday’s 38-22 victory over the Houston Texans that there “has been some dialogue with some teams,” but provided no further update.