I had night sweats for 10+ years and did the following:
You lose the ability to regulate your temperature properly, so if you get cold and try and warm up, you get too hot and vice versa. It is best to keep temperatures of the room/bed as even as possible, whilst still allowing yourself to cool down.
Make sure you are properly hydrated during the day.
Don't go to bed too hot (eg from a bath or shower) or too cold (from sitting still all evening). Take time to warm up/cool down.
Wear a cotton (absorbent) nightdress with straps, so you can cool down if you get hot. I have cold feet, so wear fleece bedsocks that I can slip off with minimum waking.
Avoid having a big difference in temperature eg cold room and thick duvet. Have a warmer room (about 16c) and lighter duvet. In cold weather, put a blanket over the foot end and move it up or down according to what feels best.
If you are hot in the night, stick shoulders/feet/legs (bottom!) out of the bed as soon as you are aware.
Keep a glass of water by the bed for when you wake up as it helps cool and makes up for the sweating.
Fan in summer
Also, keep a spare nightdress handy for changing in the night. I was never sure what to do with the bed - getting back into a cold, wet bed is yucky
but I never could bring myself to wake DH up and change the bed. A comfortable towel to sleep on might help with the bottom layer, but it was always the top that was the problem.