WordPress Login Redirect Loop: Fix Being Sent Back to wp-login
You type the right password and WordPress sends you back to the login page. The cause is usually cookies, address settings, caching…
Old PHP stops getting fixes, but a rushed update can break plugins. Learn to check your version, test compatibility and switch PHP safely with a way back.
To update PHP on WordPress you change the PHP version your hosting runs, not something inside WordPress itself. Older PHP versions stop receiving security fixes, and newer ones are usually faster, but a plugin or theme written for an older version can break after the switch. This guide explains how to check your version, which versions are supported, how to test compatibility on a copy, how to switch in your hosting panel and how to go back if something breaks. It also links to the recent PHP security release, which makes the topic more urgent.
Check your PHP version in Tools → Site Health → Info → Server. Compare it with the supported branches on php.net, and check that your plugins and theme support the newer version. Back up, test the new version on a staging copy, then switch the live site in your hosting panel and test again, with the old version ready for a rollback. WordPress.org currently recommends PHP 8.3 or greater, and the PHP project’s October 2026 security release makes staying on a patched, supported version important.
How this guide was prepared: it is research-based. We used php.net’s supported versions page, the PHP security advisory and WordPress.org’s requirements page listed under Sources, checked on October 23, 2026. Hosting panels differ, so we describe the steps in general terms and make no claim about your host.
According to php.net on October 23, 2026, the supported branches are 8.2 (security fixes only until December 31, 2026), 8.3 (security fixes only until December 31, 2027), 8.4 (active support until December 31, 2026 and security fixes until December 31, 2028) and 8.5 (active support until December 31, 2027 and security fixes until December 31, 2029). Anything older, such as 8.1 and earlier, no longer receives official fixes. WordPress.org’s requirements page recommends PHP 8.3 or greater and warns that older versions have reached end of life and may expose your site to security vulnerabilities.
The PHP project announced two critical security fixes on October 21, 2026, in PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35. Our article on PHP2Shell and website security explains it. A version number alone does not prove whether your host has applied a fix, because hosts can backport patches, so ask your host.

In Tools → Site Health → Info → Server you will see the PHP version, and the Status tab can warn when your PHP is outdated. Compare it with the supported branches above. Our guide to WordPress Site Health explains the screen.
Read each plugin’s and theme’s page for the PHP versions it supports and when it was last updated, and replace anything abandoned. WordPress itself checks a plugin’s declared minimum requirements when you activate it, as in “Plugin could not be activated because it triggered a fatal error”. Ask your developer to check custom code for features removed or changed in newer PHP, and look for deprecation warnings in the debug log on staging; see how to read the WordPress debug log safely.
Take a full backup and test that it restores; see is your WordPress backup really safe. Then create a staging copy that runs on the new PHP version if your host allows it; see how to set up a WordPress staging site.
Most hosts let you choose a PHP version per site in the control panel. Switch the staging copy first, test it, and then switch the live site at a quiet time. If your host offers no choice, ask them for a supported version. Keep a note of the old version so you can switch back.
Open the home page, inner pages, the admin, forms, search, login and, on a store, a full test order. Check the error log for new warnings and fatal errors. Compare speed and Site Health before and after. For an error such as a memory problem, read Allowed memory size exhausted.
If something important breaks, switch back to the old PHP version, confirm the site works and investigate on staging: update or replace the incompatible plugin, theme or code. Then try again. Staying on an unsupported version for long is a risk, so treat the rollback as temporary.
It can if a plugin or theme is not compatible, which is why you test first.
A supported one. WordPress.org currently recommends 8.3 or greater, and php.net lists which branches still receive fixes.
Often newer versions perform better, but results vary by site, so measure.
No. Hosts can backport fixes, so ask them.
Related guide: WordPress Mixed Content Warnings After Installing SSL: Fix “Not Secure”
Check your version, test on a copy and switch with a rollback ready. wpallsolution offers WordPress maintenance packages and an emergency WordPress fix if an update goes wrong. We cannot promise a result without seeing your hosting setup.
You type the right password and WordPress sends you back to the login page. The cause is usually cookies, address settings, caching…
Most break-ins start at the login screen. Use this practical checklist for passwords, two-step login, admin accounts, attempt limits and HTTPS.
A staging site lets you test updates on a copy before customers see them. Learn how to create one, lock it down…
Black FridayCyber Monday sale
Before you go,
Our biggest discount of the year on the first payment of every maintenance plan.
BF2026 at checkout