Spain struggled to break down a determined Sweden defence at the Santiago Bernabeu until Ramos struck in the 64th minute after Sebastian Larsson blocked Marco Asensio’s cross with his hand.
Two late goals in two minutes then gave the score a deceptively comfortable look as Ramos deferred a second spot-kick to Morata, who had won the foul, before Mikel Oyarzabal curled in a third.
Victory means Spain stay top of Group F, now five points clear of second-placed Sweden, with four wins out of four.
Their advantage reflects an impressive return to form after a disappointing performance in the UEFA Nations League, even if the previous three successes came against Norway, Malta and the Faroe Islands.
Luis Enrique has been absent from matches since missing Spain’s win over Malta in March due to a family emergency and he was away from the bench again, leaving his assistant Robert Moreno in charge.
“We can still improve in lots of ways,” said Moreno. “We’re looking for perfection.”
Moreno confirmed on Sunday he has been in constant contact with Luis Enrique and Ramos has insisted the situation is not affecting the players.
There have been many given a chance to impress, with eight changes from the 4-1 thrashing of the Faroe Islands on Friday taking the number of starters to 24 in the last four games alone.
Dani Parejo and Fabian Ruiz both impressed in midfield but Asensio and Isco lacked spark again in the final third, with Rodrigo Moreno also ceding ground to Morata in the central striker spot.
Kepa Arrizabalaga had little to do in goal but his third consecutive start suggests he is now not just an alternative to Manchester United’s David de Gea but the side’s preferred keeper.
“I think in Spain we don’t watch so much foreign football,” Moreno said. “If they’d seen the end of the season Kepa had, nobody would be surprised by our decision.”
Sweden’s disciplined defence carried them to the World Cup quarter-finals almost a year ago and Spain only really rattled them for five minutes in the opening half.
The first of a flurry of chances saw Fabian’s shot palmed over by Robin Olsen, who then parried away a dipping volley from Parejo.
Even when Spain had the ball in the net it was crossed off, incorrectly, for offside, after Rodrigo tapped in Parejo’s cutback. VAR, not in use until the tournament’s finals, would surely have intervened.
Albin Ekdal was also fortunate not to concede a penalty when he placed both hands on the shoulders of Ramos but referee William Collum was not so tolerant after half-time.
Asensio’s cross was blocked by the outstretched arm of Larsson for a clear spot-kick, leaving Ramos to whip right-footed into the bottom corner.
Sweden had not been without chances of their own, Ludwig Augustinsson firing a shot into Ramos before Robin Quaison hit straight at Kepa.
But they capitulated late on as Spain added two in the 85th and 87th minutes. First Morata, on for Asensio, drew a foul from Filip Helander with an aggressive run into the box and, after Ramos deferred, struck the penalty into the corner.
Then, Oyarzabal, who had replaced Rodrigo, darted inside Augustinsson and curled a brilliant shot between Olsen’s hand and the far post to wrap up a hard-earned win.
For more news your way, download The Citizen’s app for iOS and Android.
Download our app and read this and other great stories on the move. Available for Android and iOS.