Gilchrist, who was named as club co-captain ahead of the current season, and has made 17 appearances in a disappointing season for his club.
"Admittedly, it's been a tough year and we're disappointed with recent results," said the 26-year-old.
"But I'm looking forward to helping the club move forward. I'm excited to see what this group can produce."
Edinburgh reached the quarter-finals of the European Challenge Cup, losing to La Rochelle, but lie ninth in the Pro12.
Richard Cockerill takes over as head coach this summer and Gilchrist is hopeful that his side can achieve better results in future seasons.
"I'm desperate for this club to be successful and I believe we will achieve what we want to in the next few years," he said.
"If you look across the board, we've got competition for places and every week people are going to be battling for their spot.
"The contest for a place in the second-row has been really good for me as I feel it's making me a better player and I hope that I'm making the other locks better too."
Gilchrist was handed a one-year contract last March despite his appearances being limited by two arm fractures in two years.
However, he earned his 16th cap in the 29-0 Six Nations win over Italy after being called up to the Scotland squad to replace the injured Richie Gray and acting Edinburgh head coach Duncan Hodge thought the lock would continue to be a positive influence.
"It's great to have Grant, another experienced internationalist, commit to the club for the coming seasons," he said.
"He's a quality operator around the park and at set-piece - and is a natural leader in a young squad.
"His presence is one valued by the staff and players.
"He's had an unfortunate run with injuries over the last few seasons, but it's great to see him back and battling for his spot in a competitive second-row."
Scotland lock Grant Gilchrist has signed a new two-year contract to remain with Edinburgh until May 2019.