Leighton Baines scored a stoppage-time winner to secure victory for Merseyside in the inaugural Game4Hope at Goodison Park.
The former Everton favourite had his spot-kick saved but converted the rebound to snatch victory for the hosts against a Rest of the World side that featured World Cup and Ballon d'Or winner Rivaldo and Clarence Seedorf - a four-time Champions League winner.
Baines, now assistant manager at Everton, finished from close-range to seal a 3-2 win for the hosts on a star-studded charity evening.
A fitting finale for Baines
It was a fitting finale given how the ex-England international had been one of the best players on the pitch, repeatedly bursting down the left under the latticework of Archibald Leitch in a familiar scene for Blues supporters.
Baines was among modern Everton stars including Tim Cahill, Phil Jagielka and Yakubu in a side that also included former Liverpool FC winger Ryan Babel and celebrities from the world of media, acting and sport - from actor James Nelson-Joyce to the content creator known as StillRyan, who was one of the better performers on the night.
They came up against a Rest of World XI that featured the likes of Jimmy Floyd Hasselbaink, Wes Morgan and actor Tamar Hassan.
Second-half drama
Baines' goal denied the visitors after former Wales international Rob Earnshaw scored twice in the second half to tie the game after a stunning curling effort from Jermaine Beckford, who spent a season at Everton during David Moyes' first spell in charge of the club, added to the lead Merseyside took into half-time.
Merseyside had deservedly led at the break, the opening goal coming late in the half as former Blues and England women's winger Toni Duggan volleyed in when a deflected cross looped towards her inside the Rest of the World box. The chance was created by StillRyan, whose menacing cross caused panic in the visitors' defence and it was one of several highlights for the Evertonian, who also forced a good save from Joe Marsh and marshalled Seedorf well from right-back, resisting his efforts to cut inside the box and stepping inside the former AC Milan and Real Madrid star to ease him off the ball midway through the half.
StillRyan also left Seedorf in a heap in the centre circle after stealing the ball from him in another impressive passage from the right-back.
Attacking threat and celebrations
Most of the attacking threat came from the other side of the home defence, with Baines marauding down the wing to wreak havoc. He picked out Tony Bellew and Duggan in the box - with both missing the target when well-placed - and then found former team-mate Cahill, whose diving header flew just wide.
Harry Cooksley, a non-league player with Bracknell Town who gained fame through Love Island, posed problems for the Rest of the World side, repeatedly linking up with Seedorf, who started to control the game as the half wore on and should have scored when he broke through the Merseyside defence but slotted his effort wide of David James' post.
Baines' late winner sparked celebrations for the hosts in a match that was more about the cause than the result. Thousands bought tickets for the event, held to support homelessness charity Shelter and the work of Everton in the Community.
Five stars of the game
Leighton Baines: The left-back still spends his days at Finch Farm and still has what it takes, judging by this display. He caused all sorts of problems as he travelled down the left flank, whipping in dangerous ball after dangerous ball. He could have had three assists alongside his winner.
StillRyan: The content creator was impressive on the other side of the Merseyside back four. He held up well against Seedorf, forced Marsh into a good save and caused the problems for Duggan's opener.
Clarence Seedorf: A touch of class, as expected, in the heart of the Rest of World side. So many touches of class once he got a foothold in the game. Some lovely footwork for the first of Earnshaw's brace.
Harry Cooksley: The Bracknell Town player and Love Island star was one of the better players on the pitch and central to the better attacking moments of the Rest of the World side.
Toni Duggan: Linked up well with her teammates across the first half and gave Merseyside the lead with a cool volley in front of the Park End.