Working out in the morning vs evening

I want to work out in the evenings after I get off at 5pm but I don’t want it to power up my brain and get more energy and keep me up late but at the same time I don’t want to get up at 5am to workout lol. Which ones better??