Harry Styles literally had the time of his life after appearing on "Saturday Night Live" over the weekend. He and his One Direction bandmates appeared in a sketch and performed a few of their songs on the show ... but it looks like the good times kept rolling at the "SNL" after party! Harry created some amazing midnight memories showing off his best dance moves with Kristen Wiig.

During the after party,  Dirty Dancing's iconic song "(I've Had) The Time of My Life" poured out of the speakers ... and Harry just couldn't contain himself. He grabbed Kristen Wiig, and the pair amazingly broke it down on the dance floor. And had the time of their lives.

Check out Harry and Kristen's amazing dance moves below:

So the kid from @onedirection and Kristen Wiig got on a table and danced tonight at the SNL after party. So that's a thing.

Ein von Nick Simmons (@nickseesthings) gepostetes Video am

Mr. & Mrs. Claus @harrystyles #kristenwiig

A video posted by Gavin Doyle (@savethesociety) on