How to light a scene with a skybox as background and have a HDRi or sun in the world environment?
If you are using a mesh for the &quot;skybox&quot;, all you need to do is make the material visible to camera, but transparent for all other rays. A light path node is used as mix factor in a mix shader node for this.
Then use a normal environment texture in the world.

If you have a real skybox texture then use it on the world as enviroment along with another texture to light the scene, and use a light path node to control the visibility. The camera will see one background, but the scene will be lit by the other.