The 26-year-old will move to Glasgow in the summer to bolster the scrum-half roster and will be at Scotstoun until at least May 2017.
Hart joined Edinburgh from Super Rugby side NSW Waratahs in 2013 and scored a try on his debut against Ulster, after coming off the bench at the Kingspan Stadium.
The New Zealand-born scrum-half has gone on to make 24 appearances for the GUINNESS PRO12 side, scoring five tries, including a crucial touchdown in his man of the match performance against the Ospreys at Myreside last month.
He played for the New Zealand under-20s in the 2008 IRB Junior World Championship, where he kept current All Blacks scrum-half Aaron Smith on the bench throughout the tournament.
Hart qualifies to play for Scotland through his Glasgow-born grandmother and was called up to the Scotland squad for last year's summer tour.
He made his debut for Vern Cotter's side as a substitute in the win over Canada in June and now has three caps for his country, after starting in the win over Argentina and coming off the bench in the defeat to South Africa.
Hart was close to signing with Glasgow in 2012, before the club secured Fijian scrum-half Niko Matawalu and Gregor Townsend says he's delighted to have finally got his man.
He said: "I was really impressed with Grayson when I first saw him when he was with the Waratahs in 2011/12. The following year we were in discussions with him about signing with the Warriors but he stayed in Australia, before moving to Edinburgh the following year.
"He's a scrum-half with a wide range of skills and I believe he will bring something different to our squad next season, competing with Henry (Pyrgos) and the other scrum-halves for the No. 9 jersey.
"He is in great physical shape, plays rugby with his head up and has a very good passing game. He will be another excellent addition to our group and I believe he will continue to improve within our environment."
Grayson Hart said: "I'm really looking forward to working with Gregor (Townsend) and the other coaches at Scotstoun next season and competing for my place in the team.
"I've enjoyed the last couple of years in Edinburgh, but this is a new challenge for me, working with a different group of boys.
"I like the way Glasgow play and I feel their style of rugby will really suit my game.
"This is a great opportunity for me to continue to develop and improve as a rugby player in what looks like a great environment to be a part of.
"I'm excited about moving through to Glasgow in the summer, but at the moment I'm fully focused on trying to help Edinburgh finish in the top six."
Guinness PRO12
Suite 208, Alexandra House,
The Sweepstakes
Ballsbridge, Dublin 4, Ireland