WordPress wp-admin CSS has broken and shows 404 on all pages [Fixed]
Problem:
One day after login the WordPress website I saw the dashboard is unstyled, sitting in the top left corner. all the CSS styles are gone.
When I click any wp-admin link like Post, Pages, Appearance, Plugins, etc I get a 404 error page. So I was unable to change anything from WordPress dashboard. Although I can access all the public pages from the website front end.
Solution:
I’ve searched on google and tried everything I can. Disabled all plugins, default theme, .htaccess to add site address. Changing Permalink wasn’t possible for me because I get a 404 page when I try to change it.
Finally, I found the problem. There was an unexpected .htaccess file in the wp-admin folder.
This tiny .htaccess file denying all “Deny from all”. Not sure how this .htaccess code generated.
After deleting this .htaccess file from wp-admin folder Dashboard is loading normally like before. It was a big relief 🙂
I have found the solution here.