Most of the mess that follows a new bag of food is avoidable, and the cause is speed rather than the food itself. The community of microbes that digests a pet's meals is tuned to what it has been eating, and swapping everything at once leaves it briefly out of its depth. Ease the change in and the gut adjusts quietly.
The week-long swap
The reliable method is to blend the two foods and tilt the mix a little more toward the new one every couple of days. Start with a small share of new food folded into the old, move to roughly half and half by the middle of the week, and finish on mostly new before dropping the old entirely. By the time the old food runs out, the switch is already done and the animal has barely noticed.
Stretch it out for a delicate stomach
Some animals need longer — a known sensitive stomach, a very young or very old pet, or a jump between two quite different diets can all warrant a fortnight rather than a week. Loose stools are the signal to slow down: hold the ratio where it is for a few more days before tilting further, rather than pressing on and hoping.
When it is not the food
A transition done gently should pass without drama. If the upset outlasts the swap, or arrives with vomiting, lethargy or a refusal to eat, the food change is probably not the whole story and a vet should take a look. A slow switch prevents the ordinary kind of stomach upset; it is not a treatment for the kind that means something else.
How long should it take to switch pet food?
About a week for most dogs and cats — start with a little of the new food mixed in and shift the balance every couple of days until it is entirely the new one. Sensitive stomachs and big diet changes can need two weeks.
Why does my pet get diarrhoea after a food change?
Usually because the change was too fast for the gut to keep up. Slowing the swap down, or holding the mix steady for a few extra days when the stools loosen, generally settles it.
Can I switch my cat's food suddenly if it dislikes the old one?
It is better not to — a sudden change risks a stomach upset on top of a cat that is already fussy. If a cat refuses food entirely, though, do not wait it out; that is a matter for the vet.