Server's IP displays Folders and files instead of Magento Frontend

[enter image description here][1]I installed Magento 2.4 with Composer 1. It's installed in the /var/www/html/ folder. When I go to the server IP on browser it just starts displaying the folder structure and files.

Temporarily I created an empty index.html file to show a blank screen.

If you need any file or config details tell me. I am a beginner so please go easy on me :)


Update: I set the base URL a***** but the domain is currently not pointed toward the server and I'm accessing it with an IP address. Would this cause issues?

Read Entire Article