While the scores were level at 0-0 around the 70-minute mark, the Argentine set-piece specialist was presented with a goalscoring opportunity from right on the edge of the box.
To the naked eye, it appeared almost impossible to score directly from the free-kick in a conventional manner, as it was simply too close to the goal.
But Messi managed to stylishly ripple the back of the net and he didn't even have to take the route of shooting under the wall.
The 34-year-old instead used the Panenka skill move - which he's perfected from the penalty spot - to dink the ball past the opposing goalkeeper.
Video: Messi's Panenka free-kick vs Espanyol
It was something many football fans had never seen before in a professional setting, although it turns out the seven-time Ballon d'Or winner was not the first to score a Panenka-style free-kick.
In 2014, Messi's fellow countryman Nicolas Gaitan netted a goal in that manner for Benfica in a Europa League match versus Greek side PAOK.
And guess what? Gaitan's effort may actually be the superior of the two...
Video: Gaitan's Panenka free-kick vs PAOK
Is that sublime strike slightly better than Messi's? We can't speak on behalf of everyone, but there's no denying that it's at the very least on a par with the Paris Saint-Germain superstar's effort.
In 2014, Gaitan was one of the most sought-after players in world football and was regularly linked with a move to Manchester United.
The 33-year-old eventually secured a transfer to a top club in Europe's big five leagues in 2016 when he joined Diego Simeone's Atletico Madrid.
It didn't really work out for him in the Spanish capital, though.
Gaitan spent two seasons as something of a bit-part player at Atletico, before moving to Chinese Super League outfit Dalian Yifang.
The man who once had the footballing world at his feet can now be found in Uruguay with CA Penarol following short, uneventful spells at Chicago Fire, Lille and Braga.