In the midst of what appeared to be a bleak scenario, with even thugs and looters entering the fray, Egyptians stood firm by doing what they do best.
The jokes showed up from the very beginning, the first one spreading in the early hours of Tuesday 25 January. The hearts of Egyptians were filled with excitement in anticipation of large-scale protests against poverty, unemployment and a corrupt government.
While Lebanon was the centre of attention after violent demonstrations erupted against Hezbollah's nomination of a new prime minister, Egypt's quiet streets made it seem as though no one intended to lose sleep over the expected protests during a national holiday in the country.
"Egyptians knew that police forces were at full alert, so they decided to deceive them and hold their rallies in Lebanon," went the first joke. A few hours later, thousands took to the streets in an epic march to Tahrir Square and the joke was made to look hollow.
The Tahrir protesters held aloft mocking banners after growing increasingly frustrated with Mubarak's desperate attempts to cling to the presidential seat.
"Please leave, my hand is hurting me," read one banner while another said "you must leave because I need to cut my hair." Mubarak’s attempts to appease the demonstrators also came in for mockery, with one depicting a computer and the message "cannot install freedom, please remove Mubarak and try again."
Others wrote the word 'leave' in numerous languages, including the ancient Egyptian hieroglyphic script.
The carnival atmosphere saw people record funny videos, which included an attempt to remove Mubarak using traditional Egyptian method Zar, a traditional song and dance exorcism ritual.
A Tahrir-based protester believed he would not find better occasion to celebrate his marriage. A wedding officiant said blessings amid enthusiastic cheers from the huge crowd, who chanted ‘the groom demands the removal of the regime’.
“My wife and I agreed that our coming baby will be named either Tahrir or Strike,” the groom said in a television interview with a big smile on his face.
Jokes also swept social networking site Facebook, which played a pivotal role in the ouster of the 82-year-old ruler.
Many of the antics were derived from the departure of former Tunisian president Zine al-Abidine Ben Ali. In one of them Ben Ali, who is now based in Jeddah, Saudi Arabia, told Mubarak "Bring a Playstation joystick with you when you come."
A fabricated Facebook conversation that involved the likes of Mubarak, his son Gamal, Ben Ali and Libyan leader Muammar Gaddafi was also drawn up.
In his status, Mubarak wrote he was not sure whether he would be able to practice the Friday prayer in Egypt or Jeddah. Ben Ali liked the status while Gamal, who widespread reports said was being groomed to succeed his father, reacted furiously.
“No dad I will not accept that, you promised me I would be the next president,” he replied to his father.
In another joke, Mubarak goes to heaven where he meets former Egyptian presidents Gamal Abdel Nasser and Anwar El-Sadat.
"What was the cause of your death, poison or assassination?" they ask Mubarak, who replies: "Facebook."
Nasser was allegedly poisoned in 1970 while Sadat was assassinated 11 years later by an army soldier who was later sentenced to death.
Egyptians feared the worst when thousands of prisoners were set free in the wake of the turmoil, thanks to an inexplicable decision by police forces to pull out of streets after failing to repress the demonstrations.
People had to protect their homes at night, yet still retained their sense of humour. Setting up numerous checkpoints to search any suspects and creating passwords to keep trouble out were materials for further jokes.
"A man might be a drug addict and still have the authority to stop and search a police car," was one joke.
The unusual sight of the military taking to the streets had people greeting them with flags and even providing them with food and mineral water to help them make up for the police absence, as well making light of their presence. One joke mocked their brief, serious announcements:
"Communiqué number six: The higher military council vows not to withdraw its troops from the streets unless it makes sure every Egyptian takes pictures beside the tanks."
The reputation of the Egyptian sense of humour was also evident elsewhere in the world. Maher Amin, an Egyptian citizen who works in Saudi Arabia, was stopped by a policeman because he was not wearing his seat belt.
"When he knew I was Egyptian, the policeman said he would not confiscate my driving license but only if I told him a joke," Amin told Ahram Online. "I told him that if Egypt manipulates a successful revolution, it will meet Tunisia in the quarter-finals. He burst out laughing and gave me the green light to move on!"
Egyptian vice-president Omar Suleiman announced last on 11 February that Mubarak stepped down from his post, sparking wild celebrations in the country and giving people more opportunities to showcase their hastily-made jokes.
A Tahrir banner at the end of the revolt might have summed it all up. "Why did you leave Mubarak? We were just joking, it's candid camera!"