The Scotland number one reached agreement with the Turkish outfit after undergoing medical tests in Istanbul.
The club confirmed on its official website: "According to a club statement issued by Besiktas Football Ventures, former Glasgow Rangers goalkeeper Allan McGregor has agreed to a two-year deal with the Eagles."
Speaking in an interview with BJK TV, shown on STV, McGregor said: "It's a big club, with a big tradition.
"Supposedly, they have great fans and a lot of noise in the stadium so I'm very excited.
"Every time I play, I don't like losing, which is a good thing to have.
"I'll just give my all for the team and hopefully I can do my best."
The 30-year-old had been looking for a new club after leaving Rangers when they were consigned to liquidation.
The Rangers newco, who McGregor declined to join, will dispute his right to move but the goalkeeper's former team-mates who followed the same route have been granted temporary transfer certificates by FIFA ahead of arbitration over possible compensation.
Like Rangers, Besiktas failed to meet financial criteria to gain a UEFA licence and could not take their place in this season's Europa League.
One of the top soccer cleats for control the Nike CTR360 will not let you down on the field in tight spaces.
adidas has added some color to the Predator line with this new colorway. Released on May 17. Be the first to own a pair.
Bayern Munich are kings of Germany and hope to be crowned kings of Europe at Wembley later this month!
The adidas Nitrocharge is the most talked about new cleat in years. It was released on May 15 and will take your pitch by storm.
Chelsea won the Europa League on Wednesday. The Blues defeated Benfica 2-1 on injury time goal from Ivanovic.
The push for more color on their cleats, adidas has added the infrared colorway to the adiZero f50 Line.
Ajax has released their away soccer jersey for the 2013/14 season. Get in the Gear.
The new PUMA evoSPEED 1.2 FG. A great new soccer cleat with classic look and first time for PUMA to be on the cleat.
Borussia Dortmund hears Wembley Calling and are headed to London for the Champions League final.
The Liverpool 2013/14 soccer jersey is available for pre-order. The Reds are eager to compete for silver next season.