This is the exact same problem I was having. I found a ton of posts on this, and only found bits and pieces of my answer. Many of the posts suggested it was a problem in the .htaccess file, which it DID turn out to be. Here’s my unique situation and how I resolved it.
I installed a fresh installation of wp into a subdirectory on an existing domain. I received the redirect error described above. I had the 301 redirect information in place in my .htaccess to redirect https://www.mysite.com to mysite.com.
(Code looks like this:)
Options +FollowSymlinks
RewriteEngine on
rewritecond %{http_host} ^mysite.com [nc]
rewriterule ^(.*)$ https://www.mysite.com/$1 [r=301,nc]
Now, I wanted to keep that there, because my wp blog is in a subfolder and I still wanted my root dir to redirect appropriately, but it was causing a Firefox redirect error.
So….I took out the above code from .htaccess, got into my new wp blog, went to general settings and changed wp url and blog url to INCLUDE the www (since that’s my preference)…then went back to .htaccess and readded the code for 301 redirect.
I do hope this solution helps someone. I worked on it for a while until I figured it out.