Hamlin will start his 17th career NASCAR Cup Series playoff run at the track "Too Tough To Tame" on Sunday night in the Southern 500. He warmed up for that race with his 18th career Xfinity victory -- and first since his most recent win at Darlington in 2017.
Hill was in front when the race went to a green-white-checkered finish, but Hamlin came from the high side to pass Hill in Turn 2 and went on to a six-car-length victory.
"I really didn't want to show everything we had to the very end of the race," Hamlin said. "It was a great win."
Hill said he went low into Turn 1 on the final restart that opened the way for Hamlin to take the checkered flag.
"I just need to go back to the drawing board to find out what I'm doing wrong on the restarts there," Hill said. "It's been frustrating."
Hamlin was among several Cup regulars racing Saturday. Kyle Larson got as high as second during the first 90 laps before engine problems drove him to the pits, where he sat with his hood up and his team tried to diagnose his problem.
Larson fell 31 laps behind and ended in 38th, last place.
All-time Xfinity Series winner Kyle Busch was also in the field and ran in the top 10 for some time. He finished ninth.
Ross Chastain was another Cup driver contending. He ended up 23rd.
The Xfinity Series ends its regular season next week at Kansas, with its 12-team playoff starting a week later at Bristol.