The 22-year-old Sock saved three set points in the first tiebreaker in the rain-delayed match and quickly answered a break by Querrey in the second set to get the match back on serve.
Sock became the sixth American to win the country's only men's clay-court tournament. He will climb to a career-high 36th in the ATP ranking.
"It's never easy playing friends -- (we) Americans are pretty close," Sock said on the court after being presented with the trophy. "It was a great match. I hope we play many more in the future. I've been through a lot ... a rough few months."
Sock, the Wimbledon doubles champion with Vasek Pospisil, was playing his first ATP singles final in only his third tournament of the season. He underwent surgery to repair a torn muscle in his hip in December and didn't return until Indian Wells last month.
In addition to rehabbing from the operation, older brother Eric had a potentially fatal lung infection. Eric Sock came to Houston with him for the tournament.
"I've been battling through it for him," Sock said. "Thanks for being here, Eric."
The 27-year-old Querrey, also finished second in the event in 2010. He served seven love games, but played several loose points in the two breaks he suffered. He also lost focus at crucial junctures in both tiebreakers, letting a 5-2 lead slip away in the first.
The match was interrupted for 2 hours, 20 minutes after a heavy thunderstorm soaked the courts, requiring major repairs. Sock was leading 30-love, having just belted an ace, but trailing 4-5 in games when play got stopped. After the match resumed, he lost the first two points, the second on a double fault, but never seriously wobbled thereafter.