Barcelona star Fati, who made his senior international debut off the bench in Thursday's 1-1 draw with Germany, made it 3-0 in fine fashion prior to half-time at Estadio Alfredo Di Stefano to become Spain's youngest goalscorer at 17 years and 311 days old.
Fati had earlier won the penalty from which Ramos opened the scoring and the Real Madrid great doubled the lead at a familiar venue, which is part of Los Blancos' Valdebebas training complex.
Ferran Torres got off the mark for La Roja with a well-controlled finish six minutes from time as Spain moved to four points from two matches to sit top of Group A4.
1 - Aged 17 years and 311 days, Ansu Fati has become the youngest player to score for Spain in an international game. Exciting. pic.twitter.com/zqQ3k3UXFJ— OptaJose (@OptaJose) September 6, 2020
Fati's quick feet proved too much for Sergey Krivtsov in just the third minute, with Andriy Pyatov unable to stop Ramos' penalty finding the bottom-left corner.
The Barca forward placed an effort just past the right post after tormenting Oleksandr Tymchyk on the left flank and had an overhead-kick blocked by Mykola Matvyenko in a goal-mouth scramble.
Ramos deservedly doubled the lead with a fine looping header from Dani Olmo's cross before Fati brilliantly jinked inside Ihor Kharatin and fired into the bottom-right corner off the post.
Olmo, also making a first international start, drew a smart stop from Pyatov just after the hour, while Gerard Moreno had the ball in the back of the net only to be flagged offside.
Pyatov again kept the scoreline down with a fine fingertip save from Oscar Rodriguez's dipping effort but could do nothing to prevent new Manchester City winger Torres placing a side-footed volley into the bottom-right corner.
What does it mean? Fati a star who can help Spain reign again
Spain were the dominant force of international football during a golden period that returned two European Championships and the World Cup between 2008 and 2012. In 17-year-old Fati they seemingly have a generational talent who can be the driving force behind a new crop of emerging players.
Ramos matches Di Stefano
Ramos, his country's most-capped player, will forever be regarded as a Spain legend and his double means he now sits joint-eighth in the nation's list of highest goalscorers – level with fellow Los Blancos great Alfredo Di Stefano, after whom Sunday's venue was named.
Fati not feeling the weight of international expectation
This was Fati's first start in international football, but he played with the swagger and quality of a seasoned veteran. Time and again Ukraine's defenders were left quaking by the Barca forward, who fully deserved his historic goal.
Spain prepare for their next Nations League assignment with a friendly against Portugal on October 7, while Ukraine host Germany in their third Group A4 encounter.