Bale bundled Real into an early lead, before Borja Mayoral took advantage of more sloppy defending to make it two before half-time.
Serbian Darko Brasanac gave Leganes hope of a comeback, but Real closed out the victory despite struggling in the second half.
"I'm very happy with the attitude of my players today, with 10 changes to the starting eleven, with players who haven't played much," said Real coach Zinedine Zidane. "We can't be happy with what we've done in the league in general. We lost a lot of points at the beginning, then we were a bit better but that can happen in a season. Now we have to get back to work, we have another match on Tuesday which will be our game of the year. We have a title to defend."
Zidane made sweeping changes to the team which beat Bayern 2-1 in Wednesday's first leg at the Allianz Arena, with Bale and Karim Benzema returning.
Bale boosted his hopes of a start in the second leg by hooking in a deflected Benzema effort to give Real an eighth-minute lead with his first goal since a double against Las Palmas on March 31.
Leganes had stunned Real with a 2-1 victory at the Santiago Bernabeu in January to reach the Copa del Rey semi-finals, but struggled to make any inroads against their dominant hosts.
Daniel Ceballos fired narrowly over, but the soon-to-be deposed league champions doubled their advantage on the stroke of half-time.
Mayoral tapped in from close range after Leganes goalkeeper Pichu Cuellar totally missed a left-wing cross, with offside appeals waved away as defender Unai Bustinza had got a touch to the ball on its way through.
It was the 21-year-old Mayoral's second La Liga goal, having also netted against Real Sociedad in September.
Leganes grew into the game after the break as Real's thoughts perhaps turned towards Bayern, and Miguel Guerrero wasted an excellent chance to halve the deficit as he headed wide from a Nabil El Zhar cross.
But the away team did pull one back in the 66th minute, as Nordin Amrabat forced his way to the byline and squared for Brasanac to tap in from close range.
On-loan Watford winger Amrabat was proving dangerous, and the Moroccan saw a low shot saved by stand-in Real goalkeeper Kiko Casilla.
Leganes continued to pile on the pressure, with Casilla making a brilliant stop to deny Bustinza.
Leganes defender Gabriel sent off in injury-time, as Real clung on for the three points after a below-par performance.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ