The Braves have a two-game lead over Philadelphia in the NL East after the Phillies lost to the New York Mets. Atlanta ended a four-game losing streak.
"It's been a good day, especially for me," Rosario said. "It was a really tough series for us with the Giants here."
The Giants got just four hits and had their lead in the NL West cut to one game by the Los Angeles Dodgers.
"I feel like we've been playing great baseball, and (the Dodgers) have been matching us," San Francisco's Kris Bryant said. "That's annoying."
Rosario, acquired by Atlanta from Cleveland on July 30, hit a double in the second inning and a triple in the third. He homered in the seventh and then singled in the ninth.
Freddie Freeman was the last Braves player to hit for the cycle, accomplishing the feat on Aug. 18 at Miami.
It was the second cycle recorded at Oracle Park since it opened as Pacific Bell Park in 2000. Oakland's Eric Byrnes achieved the feat on June 29, 2003.
Fried (12-7) allowed just three hits, striking out five and walking one. The left-hander has yielded three earned runs or fewer in 10 consecutive starts, and Atlanta owns an 8-2 record in those games.
"Max was awesome. Awesome," Braves manager Brian Snitker said.
Said Bryant: "What really makes him good is that his curveball is 25 mph slower than his fastball."
Fried and Giants starter Anthony DeSclafani (12-7) remained locked in a scoreless tie through six innings.
Austin Riley opened the seventh inning with a drive to right field and Bryant, running at full speed, appeared poised to catch the ball in stride on the warning track before the ball barely cleared his glove for a double.
Adam Duvall followed with his 36th home run, extending his hitting streak to a personal-best 15 games.
Zack Littell relieved and Rosario hit his 12th home run.
RHP Luke Jackson was activated from the paternity list and and utilityman Orlando Arcia was optioned to Triple-A Gwinnett. Jackson, who had not pitched since last Wednesday, contributed a scoreless eighth inning Sunday against the Giants. Arcia had batted .183 in 26 games this season with Atlanta.
Giants: RHP Johnny Cueto (flexor strain) tested his arm by playing catch on flat ground for 15 minutes at distances up to 100 feet. Asked whether he'll pitch again this season, Cueto smiled and delivered a thumbs-up gesture. Before Cueto threw, manager Gabe Kapler said that the veteran's next move could be an outing at the Sacramento alternate training site. Cueto last pitched for the Giants on Aug. 31.
The Braves continue their Western swing by opening a four-game series at Arizona. Right-hander Huscar Ynoa will start the series opener for Atlanta; the Diamondbacks have not announced a starter.
The Giants have a scheduled day off Monday before beginning a three-game series at San Diego. Starting pitchers are yet to be announced.
Eddie Rosario hits for the cycle
Eddie Rosario records his first cycle and the 10th in Braves franchise history.