I cant login my website on WordPress droplet. It happened suddenly, I tried a few things but nothing works. I can access the console.
The error is

Forbidden

You don't have permission to access this resource.
Apache/2.4.29 (Ubuntu) Server at 8bitbros.tech Port 443

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
1 answer

Hi there @cetinodinson,

What I could suggest is checking your Apache error log for some more information on why it is returning the 403 Forbidden error.

You can do that by first accessing your website to trigger the 403 error, then accessing your server, and then running:

  • tail -100 /var/log/apache2/error.log

Feel free to share the log here so I could try and advise you further.
Regards,
Bobby

  • The output is

    root@8bitbros:~# tail -100 /var/log/apache2/error.log
    [Sat Sep 26 06:25:03.875504 2020] [mpm_prefork:notice] [pid 1008] AH00163: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
    [Sat Sep 26 06:25:03.875636 2020] [core:notice] [pid 1008] AH00094: Command line: '/usr/sbin/apache2'
    [Sat Sep 26 06:31:37.529433 2020] [access_compat:error] [pid 11839] [client 167.172.186.144:41910] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601101897.4672570228576660156250
    [Sat Sep 26 06:52:28.445235 2020] [access_compat:error] [pid 11839] [client 167.172.186.144:42014] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601103148.2931590080261230468750
    [Sat Sep 26 06:52:38.921098 2020] [access_compat:error] [pid 11741] [client 185.233.247.41:48791] AH01797: client denied by server configuration: /var/www/html/wp-admin/index.php
    [Sat Sep 26 07:04:44.090458 2020] [access_compat:error] [pid 11663] [client 167.172.186.144:42080] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601103883.9220669269561767578125
    [Sat Sep 26 07:12:27.213485 2020] [access_compat:error] [pid 11839] [client 167.172.186.144:42120] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601104347.1823890209197998046875
    [Sat Sep 26 07:43:20.316959 2020] [access_compat:error] [pid 11664] [client 167.172.186.144:42286] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601106200.0277659893035888671875
    [Sat Sep 26 07:50:58.113987 2020] [access_compat:error] [pid 11662] [client 167.172.186.144:42320] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601106658.0839550495147705078125
    [Sat Sep 26 07:59:18.134025 2020] [access_compat:error] [pid 11741] [client 167.172.186.144:42348] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601107158.0755701065063476562500
    [Sat Sep 26 08:10:10.519845 2020] [access_compat:error] [pid 11663] [client 167.172.186.144:42428] AH01797: client denied by server configuration: /var/www/html/wp-cron.php, referer: https://8bitbros.tech/wp-cron.php?doing_wp_cron=1601107810.4498639106750488281250
    [Sat Sep 26 08:10:15.547132 2020] [access_compat:error] [pid 11839] [client 185.233.247.41:48980] AH01797: client denied by server configuration: /var/www/html/wp-admin/index.php
    
    
    • Hi there @cetinodinson,

      Indeed it looks like that the Apache service is unable to read the index.php file that’s inside your wp-admin folder:

      client denied by server configuration: /var/www/html/wp-admin/index.php
      

      You need to check a couple of things:

      • First make sure that the Apache user has read permissions for that folder and files:
      • ls -lah /var/www/html/ | grep wp-admin
      • ls -lah /var/www/html/wp-admin

      If the files are not owned by the Apache user, you could change the ownership with the following command:

      sudo chown -R www-data:www-data /var/www/html/wp-admin
      
      • If the folder is owned by the Apache user, make sure that there are no deny rules in your .htaccess file:
      cat /var/www/html/.htaccess
      

      And also check if there is an .htaccess file inside the wp-admin folder

      cat /var/www/html/wp-admin/.htaccess
      
      • One final thing that could be causing the problem is a security plugin if you are using one. What you could do is temporarily disable that plugin and see if it works.

      Let me know how it goes.

      Regards,
      Bobby

Submit an Answer