He continued to participate in MotoGP as Ducati's wild card rider in 2017 and 2018. During a practice session for the 2018 Italian Grand Prix he suffered a severe crash at the end of the start/finish straight and was hospitalised with a concussion. He made a further three wildcard entries in Italy, San Marino, and Valencia in 2019. In 2017, 2018 and 2019 he won again the CIV Superbike Championship. In 2020, Pirro substituted the recovering Francesco Bagnaia at Pramac for the Austrian round.