Stephen Curry and Klay Thompson combined for 54 points on 20-of-43 shooting, with Thompson tallying 30 and five three-pointers.
The Rockets sliced what was a 14-point, fourth-quarter deficit to 104-103 on a three-point play by Chris Paul with 10.8 seconds remaining. But Curry sank two free throws with eight seconds left and, after James Harden missed the second of two free throws with 6.4 seconds left, Andre Iguodala tracked down the loose ball in the backcourt for Golden State to seal the victory
Thompson, Cousins and Curry (24 points) were the only Warriors to score in double figures. Golden State shot 49.4 per cent from the floor and finished 10-for-10 from the free-throw line.
Paul finished with 24 points and was instrumental in engineering the rally down the stretch of the second quarter. While the Rockets pulled even at 52-52 on a Harden three-pointer with 32.5 seconds left, it was Paul who scored seven points in succession to help erase a 49-42 deficit.
Harden paired 29 points with 10 assists but continued his recent struggles from deep, missing 10-of-12 threes. Clint Capela posted a double-double (13 points, 13 rebounds) but struggled to defend Cousins on the block.
The Warriors turned seven offensive rebounds into six second-chance points in the third period. Cousins recorded six assists in the first half.