The four were all aboard Air France Flight 463, a Boeing 777 headed to Paris from the island nation of Mauritius.
It was diverted to the coastal city of Mombasa after the device was found, said Joseph Nkaissery, Kenya's interior minister. He did not disclose the nationalities of the four people.
The object was analyzed and found to contain no explosives, the airline said.
Air France CEO Frederic Gagey described the object as a cardboard box containing papers, with "something like a kitchen timer" inside it.
It was found by a passenger in a cabinet behind the restroom mirror, he said. He could not say whether the object was assembled before the flight, but the materials would not usually be on board the aircraft.
'It seems like a nasty joke'
He said an inquiry will determine who planted the item in the restroom, an act he described as "stupid" and "completely unacceptable."
"It seems like a nasty joke," he said. "This is behavior which is in extremely bad taste."
The 473 stranded passengers and crew were evacuated from the aircraft by slides. They were accommodated at a hotel in Mombasa, and would travel on to France in the next few hours, Gagey said.
There had been no security failure by Mauritian airport authorities because the item contained no explosives and was not something that would be picked up in screening.
Permission to land
Nevertheless, the airline said it was reinforcing security measures in Mauritius.
The flight was headed to Charles de Gaulle airport in Paris. It requested permission to land at Moi International Airport in Mombasa after the device was discovered in the restroom, Kenyan police chief Joseph Boinnet said.
"The plane landed there safely at 12:37 a.m. local time," Boinnet said in a statement.
Airport shut down
The airport was temporarily shut down following the incident, but has since reopened, according to the Kenya Airports Authority.
The island nation of Mauritius sits in the turquoise waters of the Indian Ocean and is a popular tourist destination known for its pristine beaches.
Mombasa, which is along the Indian Ocean, is the second-largest city in Kenya.
Kenyan authorities are working with investigators from France and Mauritius.