cant relax my body

for months now I haven’t been able to sleep until I’m too exhausted to stay awake. I stay up hours throughout the night from discomfort, restless body and stomach pain. I have melatonin and it doesn’t help much and makes me wake up before getting enough sleep and doesn’t let me fall back again. I watch stuff while I’m trying to fall asleep bc if there’s nothing to listen to then it’s even worse. I don’t know how to make my body relax.