Fix 403 Forbidden or upload permission errors by setting proper ownership and modes.
Step-by-Step Instructions
- Set web directory ownership to the web server user (www-data on Ubuntu).
- Set directories to 755 and files to 644.
- Never use 777 permissions on production servers.
sudo chown -R www-data:www-data /var/www/html
sudo find /var/www/html -type d -exec chmod 755 {} +
sudo find /var/www/html -type f -exec chmod 644 {} +Pro Tip: Keep sensitive files like .env or configuration.php at chmod 600 or 444.
Need assistance? Open a ticket in the A1 Client Area or contact our 24/7 NOC Engineering Team on WhatsApp at +1 (406) 229-9597.