On 13 September 2017, Boateng made his comeback after 115 days on the sidelines in the Champions League match and provided one assist to Joshua Kimmich's late goal after being subbed on in a 3–0 victory over Anderlecht. On 21 December, Boateng scored a header in a 2–1 win as his side knocked their fierce rival Borussia Dortmund out of the DFB-Pokal during the round of 16 match. On 27 January 2018, Boateng scored another header in the league match and his first league goal since November 2013 as his side made a come back from two goal behind to finish the game with a 5–2 victory over 1899 Hoffenheim. Boateng made his 250th appearance for the club in a 6–0 victory over Hamburg on 10 March. On 11 April, Boateng and his teammate Thomas Müller made their 100th European appearance in the Champions League match against Sevilla as the game finished 0–0 draw. On 26 April, Boateng suffered thigh muscle injury during the Champions League semi-final first leg match against Real Madrid in which the game ended 2–1 loss for his sides and the injury made him miss all the remaining matches of the season. He finished the 2017–18 season with two goals in 31 appearances.