Begin by asking the other person directly what you can do to help. “What might I do to support you?” “What would make it better?”
If they are unable (or unwilling) to share, ask yourself: What helped me when I felt similarly? Or: What would have helped me?
Think about how the other person would best receive your help. Present your offers of help as options that can be adapted for their situation rather than an absolute solution. You might present the idea as ‘something that some people find helpful’.