I want to make a realistic solar system

Hi, I want to make a game kind of like no mans sky, and i dont know how to do the planets, what i want is planet gravity, the planets orbit around a star and moons that orbit planets. I would like the orbit to be smooth and the player doesnt notice it. Thanks if you could help.