The 23-year-old captained the German side to fourth place in the Bundesliga last season and has 41 caps for Switzerland.
An Arsenal statement read: "Arsenal have reached an agreement with Granit Xhaka to join the club on a long-term contract for an undisclosed fee."
The transfer is still to be officially completed but Arsenal have confirmed Xhaka's contract will begin on July 1.
The former Basle man will become the Gunners' first major signing of the summer as Arsene Wenger looks to build a squad capable of challenging for the title next season.
"Granit Xhaka is an exciting young player, already with good Champions League and Bundesliga experience," Wenger said.
"We have been watching him for a long time now and he is a player who will add quality to our squad.
"We wish Granit a good Euro 2016 with Switzerland and look forward to welcoming him to Arsenal ahead of next season."
Arsenal were eager to agree the deal before Xhaka joined up with the Switzerland squad for Euro 2016, where he will be up against France, Albania and Romania in Group A.
The midfielder is known for his tackling, fitness and feisty character, and should add some much-needed steel to the Gunners' line-up next season.
He also has experience of winning trophies, having collected two Swiss league titles and the Swiss Cup in 2012 when Basle completed the double.
Xhaka was named the league's young player of the year that season and was rewarded with a move to Gladbach in 2012.
He played four seasons for the German club in the Bundesliga, making 108 appearances and scoring six goals.
Source : PA
Source: PA