The Spanish giants scored the only goal of the game after 18 minutes through Toni Kroos despite coming under early pressure from the hosts.
It was a mixed display from the visitors, with Madrid failing to maintain their performance during the victory in Istanbul.
However, the Turkish team lacked a clinical edge, and Real were let off the hook during Gala's best moments.
The hosts were the faster out of the blocks, with the away side initially appearing disjointed, but it was Real who took the lead against the run of play.
Karim Benzema fed Eden Hazard in the box, and the Belgian cut the ball back for Kroos to fire home.
The German's shot took a decisive deflection that helped the ball past goalkeeper Fernando Muslera.
Gala were stunned by the strike, and the momentum they had quickly built up evaporated. However, the home team continued to work with the ball at their feet despite Real's attack becoming more active and enthused.
Hazard found plenty of space on the left, and the former Chelsea forward was busy throughout the first half.
Squawka's Muhammad Butt complimented Zinedine Zidane's central midfield and commented on its potential:
Gala slowly found their confidence again, building towards half-time, and Younes Belhanda forced Thibaut Courtois into a save to deny an equaliser before the interval.
The contest was scrappy, and neither side could put together cohesive waves of passing before the referee blew for the end of the first half.
Benzema had a chance to test Muslera early in the second half, but the Frenchman could not beat the 'keeper as he sprinted into the box.
The game remained a messy affair, and the midfield became congested after a series of mistakes on the ball.
Hazard produced a stunning miss shortly after the hour mark. The attacker rounded Muslera only to fire his shot against the crossbar.
The Super Lig side continued to hunt for an equaliser in the last 15 minutes, throwing bodies forward, but Real's defence stood firm against the increasing pressure.
Hazard appeared glum as he was substituted with 12 minutes remaining, but it was his assist that aided Real to a vital yet unconvincing win.
Gala are back in Super Lig action on Sunday away to Besiktas. Real next feature in La Liga against Leganes at the Santiago Bernabeu Stadium on Wednesday, October 30.