The 26-year-old tighthead has spent the last seven years at the club, and was capped by Scotland in the Six Nations defeat by Ireland at Murrayfield in 2019.
The Irvine-born Rae made his Glasgow debut against Munster in February 2015.
“I’ve loved my time here at Glasgow Warriors,” glasgowwarriors.org
“Playing for my boyhood club has been a dream come true but it’s time for a new challenge. I’m really excited for what’s in front of me and looking forward to getting started at Bath.”