The 31-year-old Brazilian forward was a free agent after his contract with Liverpool was terminated at the end of last season.
After joining the Reds from Hoffenheim in 2015, Firmino scored 111 goals in 362 appearances.
He is one of many high-profile Saudi acquisitions this summer, and he joins Senegal goalkeeper Edouard Mendy at Al-Ahli after leaving Chelsea last week.
Along with Karim Benzema, Ruben Neves, and Marcelo Brozovic, N'Golo Kante and Kalidou Koulibaly have also left Chelsea for Saudi Arabia, where they will play for Al-Ettifaq, managed by former Liverpool player Steven Gerrard.
Signing the contract with his no-look finish style 🫣
— Al-Ahli Saudi Club (@ALAHLI_FCEN) July 4, 2023
Good night! 💚🫶#WelcomeFirmino
pic.twitter.com/xRumBaVg9u
Firmino, Naby Keita, Alex Oxlade-Chamberlain, and James Milner all departed Anfield as free agents this summer.
The outgoing trio received a standing ovation from teammates and supporters during the season's last game, but it was modern-day great Firmino who received the greatest acclaim.
Liverpool won the Premier League in 2020, the FA Cup in 2022, the League Cup in 2022, and the Champions League in 2019 thanks to the deadly attacking trio of Mohamed Salah, Sadio Mane, and them.
To win the FIFA Club World Cup for the first time in December 2019, Liverpool defeated Flamengo with a goal from Firmino in extra time.
He stated in March that he would leave Liverpool at the end of the season.