What is the purpose of using index.php as the main file in a PHP project?

Using index.php as the main file in a PHP project is a common practice because it serves as the default file that is loaded when a user visits a directory on a web server. This allows for easy navigation and organization of files within the project. Additionally, it helps to keep the project structure clean and easily understandable for developers.

<?php
// This is the main index.php file for the PHP project
// Add your project code here
?>