Bregman's 16th homer against Cole Irvin (6-10) was his second straight day with a two-run shot in the first. He also hit an RBI double in the seventh.
Jose Altuve doubled home two runs in the second as the AL West leaders built a big early lead in their fourth consecutive victory.
Javier (7-8) allowed one single and walked three in his first win since July 1. He was 0-5 with a 4.40 ERA in his previous six starts.
Houston's strong performance comes after the Athletics swept the Astros in a series at Oakland last month.
"They beat us out there pretty good ... so it just feels good to have a winning streak here and to get to 75 wins," manager Dusty Baker said.
At 75-41, Houston has the best record in the American League.
The Astros led 6-1 in the ninth before Rafael Montero allowed a run on a groundout by Jonah Bride. Montero walked Cal Stevenson to leave runners at first and second, and closer Ryan Pressly took over.
It's the eighth consecutive loss for the AL-worst Athletics, their longest skid since dropping a season-worst 10 in a row from May 30-June 10.
Irvin yielded five runs and eight hits in six innings in his third straight loss.
Christian Vázquez helped Houston pad the lead with an RBI single in the sixth, and Bregman's run-scoring double made it 6-0 in the seventh.
Bregman has three homers and eight RBI in his last six games.
"He's been very hot and he's worked hard to get to this point," Baker said.
Vázquez is settling in with the Astros after he was acquired in a trade with the Red Sox on Aug. 1.
"It's been very good," he said. "It was fun to see them from another now dugout, and now I'm here with them and it's always exciting to see this team playing and I'm happy to be here."
Bride singled with two outs in the second and Javier walked a batter in the third and fourth, but the Athletics couldn't string anything together against him.
The Astros chartered 10 buses to bring 500 family members and friends of the victims of the May 24 mass shooting at a Uvalde elementary school to the game.
The group attended a pregame event where Baker, Altuve, Bregman and right-hander Lance McCullers spoke and answered questions.
A little girl who was at the school at the time of the shooting didn't have a question for Altuve, but rather a request. Wearing a shirt that read "Team Altuve," she asked the star second baseman to hit a home run for her.
The 500 people were part of a group of about 3,000 from Uvalde who received free tickets from the Astros to attend the game. The team had several fundraising efforts at Sunday's game with all the proceeds going to help those affected by the shooting.
Baker said he hoped the day could provide the families a small distraction as they continue to deal with the tragedy.
"This is what we're here for," he said. "We're not only here to play ball for our town, for ourselves, for our teammates, we're here to aid the healing of people."
Oakland right fielder Ramón Laureano left in the fourth inning after manager Mark Kotsay said he felt soreness on his left side on a swing.