AMSTERDAM — Rodrigo scored the winner as Valencia beat Ajax 1-0 away Tuesday to advance in the Champions League while knocking out last season’s semifinalist.

The Spanish forward scored against the run of play in the 24th when Ferrán Torres played the ball in for him to rifle into the roof of the net.

“We've taken a great club back to where it's not been for a long time,” said Rodrigo, whose side is through to the last 16 for the first time since 2012-13.

Ajax, which won the sides’ previous meeting 3-0 in Spain, entered the game as the leader in Group H, but finished third on 10 points after Chelsea won its game against Lille 2-1. That put Chelsea and Valencia level on 11 points.

The Dutch side missed a host of chances to grab the goal that would have been enough to reach the last 16.

Gayà made an acrobatic clearance to prevent Donny van de Beek equalizing in the 43rd. The Dutch star hooked the ball over goalkeeper Jaume Doménech but Gayà somehow got back to clear off the line.

The home side showed greater urgency after the break, albeit without creating clear-cut chances until Hakim Ziyech drove the ball wide with only the goalkeeper to beat in the 67th.

The Ajax players' tempers became frayed as they grew increasingly frustrated with perceived attempts at time wasting and play-acting from the visitors.

Doménech was booked for taking too long with a kick out in the 79th. It was the game’s first yellow card, and it was quickly followed by more.

Ajax defender Nicolás Tagliafico was shown a yellow card for a late challenge on Manu Vallejo – who would have been through on goal. Ajax goalkeeper André Onana and Valencia's Dani Parejo were booked for their part in the ensuring melee, then van de Beek saw yellow for a bad challenge.

Doménech denied Lisandro Martínez in the 89th, then Ziyech at his near post in injury time as Ajax poured forward.

Valencia defender Gabriel Paulista was sent off in injury time for reacting angrily to provocation from Tadic with a push and a slight headbutt. Tadic went down holding his face despite little contact. Tadic was shown a yellow card and Valencia managed to hold on.

___

More AP soccer: https://apnews.com/Soccer and https://twitter.com/AP_Sports