The jig is up is an idiomatic expression that can be applied upon we discover that somebody tries to fool or scam us, or if someone acts mischievously.
This expression can be both used in a comical way, or seriously, depending on the context. For example, you can say the jig is up for your friend when you discover they try to prank you, but also a policeman can say it to a suspect upon receiving evidence about their crimes.
The idiom originates from the British Isles. Irish and Scottish folklore has a form of dance that is called a “jig”, which is a dynamic movement meant to attract attention or to express joy.
The dance developed around the 16th century, and eventually became part of the Baroque dance style, as the final part of choreographies. People said “the jig is up” upon getting finished with the dance, signaling that the music should stop.
In 1986, hard-rock band Aerosmith released a song which received the title Jig Is Up.
In the following decades, many other bands and producers named their releases based on the idiom.
The jig is up also stands in relation with “The Game”, an internet phenomenon, which is believed to be over when the British Prime Minister uses the idiom in a public speech.