Marinos Ouzounidis's side lost all of its previous five group games and went into the clash at Estadio da Luz having lost four of its last six matches but it successfully kept Benfica at bay for 88 minutes.
Benfica coach Rui Vitoria will have been disappointed to see winger Rafa Silva leave the field with an injury in the first half, not to mention the wastefulness of his forwards when presented with numerous early chances to score.
But after Konstantinos Galanopoulos was sent off for a second bookable offence, Grimaldo stepped up to curl home a goal worthy of winning a better game than this dead rubber between two sides whose elimination from the competition was confirmed before kick-off.
The Greek champion cut a frustrated side in the first half but for all its early dominance the Eagles failed to threaten an opener aside from Jardel's header past the post after four minutes and Grimaldo's free-kick that curled wide 10 minutes later.
A shanked ball just inside his own half by AEK's Ezequiel Ponce allowed Haris Seferovic to go through on goal moments before half-time but the Swiss forward lashed the ball wide from 20 yards.
Marios Oikonomou appeared to hold Ruben Dias's shirt as he jumped to head a corner early in the second half but the referee allowed play to go on and AEK had its best chance to break the deadlock when Oikonomou leapt to meet a corner but headed narrowly wide.
Seferovic tested Vasilios Barkas with a first-time shot from Franco Cervi's low cross, the goalkeeper getting down well to parry the ball away and the Swiss forward hit the crossbar with a free header moments later to compound his frustrating night.
Gedson Fernandes was denied in a one-on-one with Barkas shortly before Galanopoulos fouled him to earn his second yellow card, and Grimaldo's left-footed strike settled the match before Seferovic rattled one last shot off the crossbar and the post in the dying moments.