In MSFS 2024, there is no choice because it only supports DX12. In MSFS 2020, we can choose between DX11 and DX12 (beta).
In my opinion without Nvidia app and without replacing any game files as I described in the Nvidia driver topic.
It’s up to you to you which option you choose.