Britain had three medals from the first five days of competition, all gold, with two for Adam Peaty, in the 50m and 100m breaststroke and the third for Ben Proud in the 50m butterfly.
Ross Murdoch finished fourth in the 200m breaststroke on Friday's sixth day before the relay team delivered, successfully defending the title won in Kazan, Russia in 2015.
Stephen Milne and Nick Grainger made a strong start before Duncan Scott put Guy into the position to contend for the podium. And the 21-year-old Bath swimmer, who had earlier in the evening qualified for Saturday's 100m butterfly final in second place, delivered a storming final leg to touch the wall first.
Britain finished in seven minutes 1.70 seconds, 0.98secs ahead of Russia and 1.48 ahead of the United States, with Guy the only swimmer to record a split time beneath 1:44, clocking 1:43.80.
"That's pretty swift," said Bury's Guy, who was fifth in the individual 200m and sixth over 400m.
"In the (individual) 200 free final I got giddy, got excited and went for it. It doesn't work like that any more.
"Tonight I stuck to my game plan and it worked."
Britain took Olympic silver in the event behind a USA squad including the now-retired Michael Phelps in Rio, but were without a key member of the squad from 2015 and 2016 as Dan Wallace is serving a suspension following a drink-driving conviction.
Guy, who replaced Calum Jarvis following the morning heat swim, won individual 200m freestyle gold and 400m silver in 2015, but was disappointed with his individual performances at the Rio Olympics and again here.
Until Friday, when he first advanced to the 100m butterfly final behind the USA's Caeleb Dressel, who clocked 50.07, the fourth fastest time in history. Guy finished in 50.67.
Asked about his slow start to meets, Guy, who swapped Millfield for Bath after Rio, said: "Once the 400 is out of the way I can relax more. It's that burden on day one.
"The 100 fly, coming into it, hasn't meant anything. And I've got no pressure.
"What I am finding is I am more relaxed and swimming faster."
Guy even hinted at dropping the 400m freestyle from his schedule in future and adding the 200m butterfly.
Milne and Scott won Olympic silver in the relay, but Scott and Grainger had been switched out after the heat swim in Kazan, so all three won the world final for the first time.
Grainger, 22 from Sheffield, said: "I made a promise to myself in 2015 that I was going to do everything in my power not to be in that position again.
"Standing on that podium was absolutely fantastic, having a team like this is brilliant.
"When James touched at the finish, I thought I almost took Duncan out running in for the hug."
Murdoch was fourth in a 200m breaststroke won by Russia's Anton Chupkov in a championship and European record of 2:06.96.
Murdoch clocked 2:08.12 to finish 0.65 off the podium.
Molly Renshaw was sixth in the corresponding women's event, won by controversial Russian Yuliya Efimova.
Renshaw clocked 2:22.96 as Efimova, who has twice been banned for doping, won in 2:19.64.
Proud qualified for Saturday's 50m freestyle final in third place in 21.60.
Both Proud and Guy are 6/1 shots with Sky Bet to win their finals on Saturday.
Again Dressel was quickest, in 21.29, with Vladimir Morozov of Russia second in 21.45.
Holly Hibbott on Friday morning advanced to Saturday night's women's 800m freestyle final.
The 17-year-old sneaked into the final in eighth place in 8:30.66.
Katie Ledecky of the USA was quickest in 8:20.24.
Related links
Sky Bet's latest World Swimming Championship odds
Peaty wins second gold
Peaty & Proud strike gold