Massa, the Brazilian veteran of 250 grands prix, announced last September that he was bringing the curtain down on his grand prix career.
But the 35-year-old has been lured out of retirement after Mercedes moved for Bottas.
Williams deputy team principal Claire Williams confirmed that Finnish driver Bottas has left Williams to join Lewis Hamilton at Mercedes.
While Mercedes are yet to officially confirm Bottas as Hamilton’s new team-mate, Williams said in a statement: “Valtteri has been part of the Williams family since 2010 and in that time has proved a huge talent, securing nine podium finishes.
“I would like to take this opportunity to thank him on behalf of the whole team, and wish him a successful season as he joins Mercedes.
“Felipe has always been a much-loved member of the Williams family, and having the opportunity to work with him again is something we all look forward to.
“He was always going to race somewhere in 2017, as he has not lost that competitive spirit, and it was important that we had a strong replacement in order for us to let Valtteri go. Felipe re-joining us provides stability, experience and talent to help lead us forward. He is a great asset for us.”