Remove Public From URL
In this guide you will know how to remove public from url.
To Remove public from url your server must have enabled the mod_rewrite. header to check whether it's enabled or not you can run following http://yourdomain.com/phpinfo and check according to screenshot
Go to Admin / Help and Support / Remove public click on remove public button.
Remove public only work on main domain or subdomain. It will not work on if you running script on subfolder.
Remove Public Manually.
Create a .htaccess file (if not created) on root and paste below code and try to run site without public.
Remove public with Force HTTPS
To enable force https into your script your SSL must be configured properly. after that you can go to
For more detail read the article here👉: https://stackoverflow.com/questions/23837933/how-can-i-remove-public-index-php-in-the-url-generated-laravel
Hide or Denied Access .env
To Hide or Denied Access .env and create .htaccess file in the root folder and write the following code.
Last updated