Both translations are correct, it’s just that in English, we need to choose based on the verb aspect.
1. I was by your side: In reference to a past time stated or implied. For example, “I was by your side at the meeting last week.”
2. I have been by your side:
a. I was by your side and I still am by your side now.
(Português: Eu tenho estado ao seu lado)
b. I was by your side in the past, and that is relevant to the present or future situation. For example, you can count on me now or in the future, or I expect to count on you now or in the future.
would be translated as “I was” or “I used to be,” but never as “I have been.”