Legs giving up too early

I start swimming and after the first 100m legs immediately give up. They become so tired and I'm almost entirely left with my arms, swimming super slow. What do I do wrong? I am parallele to the ground and my core is solid.