Do female betta fish have to breed if close a male and she gets swollen?

No, a female betta fish doesn't have to breed if she is close to a male and gets swollen. The swelling you noticed is likely the result of a condition known as "egg binding," which occurs when the female is unable to release her eggs. This can happen due to various factors, such as genetics, water conditions, and nutrition.

It's important to monitor the situation closely and take necessary steps to ensure the female's well-being:

- Separate the female from the male: This will prevent the male from further stimulating her and potentially causing more stress.

- Check water parameters: Ensure that the water temperature is around 78°F (26°C) and the pH is around 7.0. Clean and change the water regularly to maintain good water quality.

- Offer nutritious food: Feed the female a high-quality diet that includes a variety of foods, such as live or frozen brine shrimp, daphnia, and pellets specifically formulated for bettas.

- Consider a warm bath: Gently bathe the female in warm (but not hot) water for a few minutes. This may help to relax her muscles and potentially aid in egg release.

If the female doesn't show any improvement or if she appears distressed, it's best to consult with a veterinarian specializing in fish health for proper diagnosis and treatment. Egg binding can sometimes require medical intervention to prevent complications and ensure the female's survival.