This is not to guard myself against getting tanned, but rather from getting bitten by insects
"This is not to guard myself against getting tanned, but rather from getting bitten by insects"を分解すると:
"This is not to guard myself"=「これは~から自分をガードするためではない」
"against getting tanned"=「日焼けしないように」
"but rather"=「ではなく、むしろ」
"from getting bitten by insects"=「虫し刺されないために」