Rats desert a sinking ship.
This proverb means that people or things that are in trouble or failing will quickly lose their support. People will leave a situation or group that is in decline.
The idiom is used in reference to people abandoning an enterprise once it seems likely to fail, has shown great linguistic tenacity, having been in regular use for over four hundred years. However, the wording and form of this standby has changed quite a bit over the centuries.
The original setting for the fleeing rats was a decrepit house, one that was on the verge of falling down. Both rats and mice, in the 16th century, were said to have the ability to know when a structure was on the verge of collapse, and would accordingly decamp some time before this happened. By the early 17th century the behavior of the rats begins to see use as a simile.
Don't suffer your Selves to be buffetted from Post to Pillar, by Pinning your Faith upon such that propose no more than to find a way out for themselves, like Rats that quit the House before it falls.
— Anon., A Dialogue Between Two Members of the New and Old East-India Companies, 1600Some think, that the Rationall Spirits flye out of Animals, (or that Animall we call Man) like a swarm of Bees, when they like not their Hives, finding some inconvenience, seek about for another Habitation: Or leave the Body, like Rats, when they finde the house rotten, and ready to fall.
— Margaret Cavendish Newcastle, Philosophical Fancies, 1653