<p>/login is the default login page for Craft (see <a href="https://craftcms.com/docs/config-settings" rel="noreferrer">https://craftcms.com/docs/config-settings</a> and scroll down to the users section ). You can override it by adding something like this to your config file:</p>

<p>'loginPath' => 'members/login',</p>

CC BY-SA 3.0
2017-10-08T23:00:59.247Z
2017-10-08T23:00:59.247Z
Roi Agneta
<p>I have a structured channel setup to house all the static pages on the site. All of the pages display fine on the page entry template. But the <code>/login</code> page does not. It displays fine in Live Preview. But on the actual site it immediately redirects to the homepage.</p>

<p>Is <code>/login</code> a protected keyword or something?</p>

<p>My .htaccess file is quite normal</p>

<pre><code>&lt;IfModule mod_rewrite.c&gt;
RewriteEngine On
RewriteRule ^(.*)/$ /$1 [L,R=301]

# Send would-be 404 requests to Craft
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/(favicon\.ico|apple-touch-icon.*\.png)$ [NC]
RewriteRule (.+) index.php?p=$1 [QSA,L]
</code></pre>

<p></p>

<p>And I have the Sprout SEO plugin handling some basic redirects. I'm at a loss to know where to even look next.  Any ideas?</p>

<p>This isn't a login form to get into Craft by the way. It's to login to a separate website entirely.</p>

CC BY-SA 3.0
2017-10-08T21:58:49.710Z
If you give the entry a different slug than `'login'` (something random, e.g. `'foobar'`) does it still redirect?
Mats Mikkel Rummelhoff
CC BY-SA 3.0
2017-10-09T18:15:12.770Z
No. If I change it, it works correctly.
Dave Joyce
<redirect><login>
/login page in Craft keeps redirecting to home page. What could be causing that?
# /login page in Craft keeps redirecting to home page. What could be causing that?

(Asked by: username_0 on 2017-10-08)

I have a structured channel setup to house all the static pages on the site. All of the pages display fine on the page entry template. But the /login page does not. It displays fine in Live Preview. But on the actual site it immediately redirects to the homepage.
Is /login a protected keyword or something?
My .htaccess file is quite normal

RewriteEngine On
RewriteRule ^(.*)/$ /$1 [L,R=301]

# Send would-be 404 requests to Craft
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/(favicon\.ico|apple-touch-icon.*\.png)$ [NC]
RewriteRule (.+) index.php?p=$1 [QSA,L]


And I have the Sprout SEO plugin handling some basic redirects. I'm at a loss to know where to even look next.  Any ideas?
This isn't a login form to get into Craft by the way. It's to login to a separate website entirely.

**Tags:** redirect, login

> **Comments:**
> **username_1**: If you give the entry a different slug than `'login'` (something random, e.g. `'foobar'`) does it still redirect?  
> **username_0**: No. If I change it, it works correctly.  

---

## 1 answers

### Answer by username_2 on 2017-10-08. Score: 5 | Accepted answer

/login is the default login page for Craft (see <https://craftcms.com/docs/config-settings> and scroll down to the users section ). You can override it by adding something like this to your config file:

'loginPath' => 'members/login',


---

