The practice session took place between the squads at the Houston Methodist Training Center. Houston and San Francisco face off in a preseason game at 8 p.m. on Saturday at NRG Stadium in Houston.
Ward and Hopkins lined up against each other before the skirmish. Hopkins beat Ward to his left, before cutting back inside during a route.
The two players interlocked grabs on each other before Ward took off Hopkins' helmet. They were briefly untangled, before Ward pushed Hopkins. The players eventually exchanged punches before taking the rumble to the ground and being joined by teammates.
Niners cornerback Richard Sherman was also involved in the scuffle. Ward and Hopkins players were thrown out of practice after the dust-up.
Texans coach Bill O'Brien was tightlipped about the melee when asked about it after practice.
"That's ridiculous," he said. "You just gotta move on. Ridiculous."
Ward, 27, is listed at 5-foot-11, 193 pounds, while Hopkins stands at 6-foot-1, 215 pounds. Hopkins was the No. 27 overall pick in the 2013 NFL Draft. Ward was the No. 30 overall pick in the 2014 NFL Draft.