Both your local and your hosted sites are messed up.
You need to consider that /public folder should be the external facing part of your website and everything else is private and not in view.
For local development, your "Document Root" should be /public and in that folder there should be a .htaccess file that includes code to redirect all requests to index.php. Index.php should not be in your URLs
For the shared hosting, often your site will have a folder like
/logs
/public_html
/cgi-bin
you should copy /public from your project (and all children) into /public_html
then you should copy everything else into your root folder.
make sure the storage folder is writeable and you have a .htaccess file in the public_html folder.