Upon arrival, he was competing for the job as the starting defensive end against Quinton Dial, Darnell Dockett, Glenn Dorsey, and Tank Carradine after it was left vacant due to the retirement of Justin Smith.
[16] Head coach Jim Tomsula named him the fifth defensive end on the depth chart to begin the regular season, behind Quinton Dial, Glenn Dorsey, Tank Carradine, and Tony Jerod-Eddie.
[20] In Week 17, Armstead earned his first NFL start and made a solo tackle during a 19–16 overtime victory over the St. Louis Rams.
[23] Armstead competed to be the starting defensive end after Glenn Dorsey was moved to nose tackle.
[24] In the season-opener against the Los Angeles Rams, Armstead recorded his first sack of the season on Case Keenum during the 28–0 shutout win.
[25] In week 6 against the Buffalo Bills, Armstead recorded a strip sack on Tyrod Taylor which was recovered by former college teammate DeForest Buckner during the 45–16 loss.
[28] Armstead finished his second season with 15 combined tackles (nine solo), a forced fumble, and 2.5 sacks in eight games and four starts.
[29] During Week 2 against the Seahawks, Armstead recorded his first and only full sack of the season on Russell Wilson during the 12–9 road loss.
[33] During Week 3 against the Kansas City Chiefs, he recorded his first sack of the season on Patrick Mahomes during the 38–27 road loss.
[34] In Week 7 against the Rams, Armstead recorded a season high five tackles and sacked Jared Goff once during the 39–10 loss.
[37] During the season-opener against the Tampa Bay Buccaneers, Armstead recorded his first sack of the season on Jameis Winston during the 31–17 road victory.
[38] Two weeks later against the Pittsburgh Steelers, he forced a fumble on James Conner which was recovered by DeForest Buckner late in the fourth quarter to help seal a 24–20 win.
[42] Two weeks later against the Seahawks on Monday Night Football, he sacked Russell Wilson 1.5 times during the 27–24 overtime loss.
[43] During Week 12 against the Green Bay Packers on Sunday Night Football, Armstead sacked Aaron Rodgers twice during the 37–8 win.
[55] During Week 18, in the 49ers final game of the regular season, Armstead recorded 2.5 sacks in a 27–24 overtime victory against the Rams.
[61] In Super Bowl LVIII, Armstead recorded one sack and six total tackles in the 25–22 overtime loss to the Chiefs.
[62] Two days after losing the Super Bowl, it was revealed that Armstead was playing through a knee injury during the playoffs, which later turned out to be a torn meniscus.