wp-admin redirects to wrong website?!

July 17, 2015 3.4k views

Hi guys, so everytime I try to go to survivelikeaboss.com/wp-admin it redirects and takes me to a blank page and the address bar says http://survivelikeaboss.com/wp-login.php?redirect_to=http%3A%2F%2Fsurvivelikeaboss.com%2Fwp-admin%2F&reauth=1

I made sure I made the URL in the WP-admin (While it still worked) as the homepage url. But I can't access wp-admin

Any ideas why?


  • Hello.
    Are your folder permissions OK?
    Which webserver software do you use?

  • What plugins do you have installed? A lot of the time caching plugins can mess this stuff up, in my experience.

  • No plugins, I only recently set up my droplet. I actually created a new droplet because of this issue. I only installed a theme, then seconds later it happened. I followed the instructions here for installation of my droplet and host: http://www.bloggertipstricks.com/install-wordpress-digitalocean.html

    I only used server pilot, putty, and digitalocean

  • I only installed the droplet and servers yesterday, no plugins. Only installed one theme. and i used serverpilot/putty/digitalocean for everything

  • Hey, @nqudimat.
    Can you please answer my two questions?
    Do you use Apache? Nginx?
    Did you use chmod to adjust your directory permissions?

  • @missaglialfio The guide i followed said this ..."Server Pilot installs Linux, Nginx, Apache, MySQL and PHP on our Digital Ocean droplet." and I folloewd the guide exactly. So yes I think i do use both.

    I did not use chmod, not sure what that it. Only putty was used

1 Answer

According to the WordPress Codex, this can happen for a large number of reasons. A large number of the fixes assume you have FTP access, so I'll assume you have that (if not you can use nano in SSH as well).

Edit wp-config.php and add these lines:


See if you can log in.

If you still can't login, you should try disabling all your plugins. Temporarily rename the plugins folder to something else, like old_plugins or something, and see if you can login.

Hopefully that helps, otherwise this webpage may prove useful :)

  • How could I do that through SSH or putty? FTP access is through the contorl panel right on digital ocean?

    The only access I have to my website is the wp-admin and digitalocean and serverpoint,

    wp-admin can't be accessed though.

    I've tried to google instructions on how to edit the wp-config through the terminal or putty, but no instructions or tutorials that I can find!

  • @nqudimat didn't you already edit this file as said in your other question?
    FTP is not natively installed in Droplets. Anyway, you can use SFTP
    But this would be pointless, you can just edit the file through the terminal:

    nano /dir/wp-config.php

    => Where dir is your Wordpress Installation directory.


  • @nqudimat Did you use the WordPress one-click application to make your Droplet? (When you were starting, did you click WordPress instead of an OS?)

  • If you used the WordPress one-click application, you could do what @missaglialfio said. The correct command you should use is:

    nano /var/www/wp-config.php

    That's the default location of the wp-config file. That command would be run in SSH of course.

Have another answer? Share your knowledge.