/ip route
add check-gateway=ping distance=2 gateway=8.8.4.4 target-scope=30
add check-gateway=ping distance=3 gateway=208.67.220.220 target-scope=30
add distance=10 gateway=ispgateway(secondary) target-scope=30
add distance=2 dst-address=8.8.4.4/32 gateway=ispgateway(primary)
add distance=3 dst-address=208.67.220.220/32 gateway=ispgateway(primary)
In the above setup, distance=2 and distance=3 represent your primary ISP and distance=10 represents your backup ISP.
This is a basic recursive type of setup that checks connectivity (through your ISP) to common web locations.
This is done to ensure the gateway is actually up and running (not just to your ISP but beyond).
You could do it with just one website( next) the above example checks both google and OpenDNS servers before switching to your backup ISP.
/ip route
add check-gateway=ping distance=2 gateway=8.8.4.4 target-scope=30
add distance=10 gateway=ispgateway(backup) target-scope=30
add distance=2 dst-address=8.8.4.4/32 gateway=ispgateway(primary)
This however is not the complete story as you stated you have dynamic ISPs.
If an ISP fails and then tries to give you a different ISP address and more critically a different ISP gateway then it may not work.
THe above seems to work well with docsis type cable connections but it does NOT work for fibre bell type connections. My experience is that the MT routers cannot handle changes in gateways in this scenario. Typically once the unit has failed the primary and goes to the secondary (my primary is fibre, my secondary cable) it does not usually go back to the primary when it is back on line due to the different gateway assignment. I have to manually look at the dhcp client setting click on the connection and hit status to see what gateway the router is detecting and then go manually to IP routes and put that into the ispgateway(primary) location in the associated ip route rule.
Now the latest editions of RouterOS lets one tinker with scripts that may solve this issue but its slightly too technical for me.
Also if looking at your routes in winbox, the black text ones are working/in use, the light blue indicate ready to be used (connected but not in use).
So in the above setup the primary connection via the secondary public web location would be in light blue as would the secondary backup isp.
newbie question here, why are you using things like googles DNS for check gateway and not getting the closest address to the device on the ISP side via a traceroute from the router?