Rea will replace BMW-bound Toprak Razgatlioglu at the factory Yamaha squad next year, partnering incumbent Andrea Locatelli.
Rea still had a year left on his contract with Kawasaki, the marque with which he scored all his six titles as well as more than a 100 race wins, but a decline in results in recent years prompted the two parties to mutually agree to an early exit.
Yamaha was initially looking for a rider within its ranks to take the place of 2021 champion Razgatlioglu, but it had a change of heart and started searching for a high-profile name that could lead it to championship glory.
Rea was announced as a Yamaha rider on Monday afternoon, hours after Kawasaki confirmed that he will be leaving the squad at the end of the 2023 season.
Rea has scored just a single win this year after eight rounds, in a wet/dry Most race, and he currently sits a distant third in the championship.
Rea, 36, won all of his world titles with Kawasaki between 2015 and 2020.
The most successful rider in the history of the championship, the County Antrim man has racked up a remarkable 119 career World Superbike race wins and 256 podiums in the 401 races he has competed in to date.