WINSTON-SALEM, N.C. (AP) A bad week for No. 17 Duke was on the verge of getting even worse. Instead of getting tense, Luke Kennard loosened up - just in time to save the game for the Blue Devils.

Kennard hit a 3-pointer with 6.6 seconds left and Duke rallied to beat Wake Forest 85-83 on Saturday.

''I thought we fought, we let out, we were free,'' Kennard said. ''We had freedom.''

Kennard finished with 34 points - one shy of his career high - and Grayson Allen had 19 for the Blue Devils (16-5, 4-4 Atlantic Coast Conference). Kennard was 6 for 6 from 3-point range and Allen went 5 for 11 from beyond the arc.

For most of the day the preseason No. 1 team appeared headed for its fourth loss in five games, trailing for more than 30 minutes and falling behind by 10 with less than 4 minutes to play.

Kennard - hampered by early foul trouble - scored 30 points after halftime. He hit each of his 10 second-half shots and scored 12 of Duke's final 15 points, including 11 after the Blue Devils fell into that late hole.

''I was kind of inward, I was thinking about, `What can I do to help us?''' Kennard said. ''I wanted to change that in the second half and just be all about what's going on around us, and not let anything affect the way I play.''

Bryant Crawford scored a career-high 26 points, John Collins added 20 and Keyshawn Woods finished with 15 for Wake Forest (12-9, 3-6), which was denied its first home victory over a Top 25 opponent since its last victory over Duke in 2014.

After Allen's 3 with 52.5 seconds left pulled Duke to 83-82, the Demon Deacons worked on the clock before Woods missed a 3 over Kennard. Harry Giles grabbed the rebound and the Blue Devils called timeout.

Allen inbounded the ball to freshman Frank Jackson, who hit Kennard as he curled around the right wing and the sophomore guard buried the go-ahead 3.

''Luke was a beast for us in the second half,'' Allen said.

Wake Forest called timeout and inbounded the ball to Crawford, who took off down the right sideline and put up a runner that missed. Collins went down hard while trying for the rebound that went out of bounds with 0.3 seconds to play.

BIG PICTURE

Duke: Maybe this rally will be the turning point that flips the season back around. Things were pretty grim around the program after the Blue Devils fell to another middle-of-the-pack in-state rival - North Carolina State - five nights earlier.

''As a team, we've just got to keep going,'' Allen said. ''We're a group of talented guys and we're good, but we've just got to come together and be a good team. It's having that belief, and I think we showed that belief.''

Wake Forest: Coach Danny Manning is still winless against ranked ACC teams, and that's partly because the Demon Deacons couldn't get Collins involved down the stretch. Facing a Duke team in serious foul trouble, Collins didn't even get any shots in the final 5 1/2 minutes.

''We have to do a better job of controlling our own destiny, meaning taking care of the things we can take care of,'' Manning said. ''Those are the things ... that can come back to haunt you.''

TENSE MOMENT

Tempers flared with 4:34 remaining after Allen missed a 3-pointer and was called for a foul for holding Crawford's right arm while going for the rebound. Crawford appeared to put his chest into Allen's shoulder, and that led everybody on the Duke bench to stand up. The only technical foul of the dust-up was given to Wake Forest freshman Brandon Childress, who rushed into the fray before being removed by Duke assistant Nolan Smith.

STAT LINE

Crawford was 15 of 15 from the free-throw line, but was just 5 of 15 from the field. Despite repeatedly beating his defender and getting to the rim, he had trouble finishing at times and missed at least four layups that could have changed things significantly.

UP NEXT

Duke: The Blue Devils visit No. 14 Notre Dame on Monday night. Duke has not won in South Bend since the Fighting Irish joined the ACC.

Wake Forest: The Demon Deacons hit the road for a rematch with Boston College on Tuesday night. Wake Forest won the previous meeting by 13 points on Jan. 3.

---

Follow Joedy McCreary at http://twitter.com/joedyap.

---

More AP college basketball: www.collegebasketball.ap.org and https://twitter.com/AP-Top25

Copyright 2017 by STATS LLC. Any commercial use or distribution without the express written consent of STATS LLC is strictly prohibited.