(just) to be on the safe side idiom
谨慎起见;以防万一
being especially careful in order to avoid something unpleasant
I'm sure it won't rain, but I'll take an umbrella (just) to be on the safe side (= to be ready if it does rain). 我知道不会下雨,但是为了以防万一,我还是要带把伞。