It was Brooklyn's second victory over Philadelphia (19-10) in three meetings.
Down 11 in the fourth quarter, the Sixers closed to 111-105 on Embiid's free throws and a 3-pointer with 3:24 left. Dinwiddie's basket extended the lead to 115-105.
Landry Shamet hit consecutive 3s in the final minute to cut Brooklyn's lead to 123-118 with 22.9 seconds left. The Nets (11-18) got a pair of free throws from Dinwiddie before Shamet nailed another 3. But Dinwiddie made two more free throws to ice it.
The Nets outscored the Sixers 19-3 over a 4 1/2- minute stretch in the third quarter to build an 87-75 lead. Dinwiddie had 12 of those points for Brooklyn, including a pair of 3-pointers.
A 10-2 run gave the Nets a 49-41 lead in the second quarter, but the Sixers closed to 57-56 at halftime.
Copyright 2018 by the Associated Press