Zealand at Basin Reserve in January 2017, Rahim was hit on the back of the helmet on the fifth day of match and immediately taken to hospital. The incident took place in the 43rd over of Bangladesh's second innings when Tim Southee bowled a bouncer that hit Rahim just behind left ear as he was trying to duck. Initial X-rays and scans to his neck suggested he was out of immediate danger. Rahim attended to the post match presentation after receiving treatment. In March 2017, during the second Test against Sri Lanka, Rahim took his 100th dismissal as a wicket-keeper. He became the first wicket-keeper for Bangladesh to reach this milestone. On 15 October 2017, during the first ODI against South Africa, Rahim became the first batsman for Bangladesh to score an international century against South Africa in any format. He was selected as wicket keeper in the Test XI of the year 2017 by Cricinfo. In November 2018, he scored 219 not out against Zimbabwe to become the first wicket-keeper–batsman to score two double centuries in Test cricket,(a third double hundred coming in 2020) His score of 219* is currently the highest individual score in a Test innings by a Bangladeshi batsman. Later the same month, against the West Indies, he became the second batsman for Bangladesh to score 4,000 runs in Tests. 2019 Cricket World Cup and after In April 2019, he was named in Bangladesh's squad for the 2019 Cricket World Cup. In the first innings of Bangladesh's opening match in the World Cup, against South Africa, he scored an 80-ball 78, contributing to a 142 run partnership with Shakib Al Hasan. Bangladesh went on to score their highest total in an ODI match, finishing on 330/6 from their 50 overs, beating South Africa by 21 runs. In Bangladesh's next match of the tournament, against New Zealand, Mushfiqur played in his 350th international match for Bangladesh. In the match against Australia, Mushfiqur scored his first century in Cricket World Cup. He scored 102* in 97 balls and became third Bangladeshi batsman to score a century in world cup. Bangladesh also broke the record of their highest total ODI runs in this match, scoring 333 for 8 wickets. In February 2020, when Zimbabwe toured Bangladesh, he scored an unbeaten 203 runs, becoming the only Bangladeshi batsman to score three double-hundreds in Test cricket. In December 2020, Mushfiqur was