# How to redirect when login

**URL:** https://meta.discourse.org/t/how-to-redirect-when-login/333296
**Category:** Support
**Created:** [October 29, 2024, 2:34am UTC](https://meta.discourse.org/t/how-to-redirect-when-login/333296 "2024-10-29T02:34:16Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![blue-sky](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blue-sky/32/381057_2.png) [@blue-sky](https://meta.discourse.org/u/blue-sky)
#### Post date: [October 29, 2024, 2:34am UTC](https://meta.discourse.org/t/how-to-redirect-when-login/333296/1 "2024-10-29T02:34:16Z")

</div>

When user login, if he/her does not config “preferences-\>profile-\>location”, I want the website redirect to “preferences-\>profile-\>location” and config it. So how to do this? Anyone knows?

---

<div class="post-metadata">

### Author: ![ondrej](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ondrej/32/198804_2.png) [@ondrej](https://meta.discourse.org/u/ondrej)
#### Post date: [October 29, 2024, 11:34am UTC](https://meta.discourse.org/t/how-to-redirect-when-login/333296/2 "2024-10-29T11:34:07Z")

</div>

👋  
You can use a theme component like these to change the default homepage.

You could add people in a group who haven’t configured their location and add `preferences - profile - location` as the URL?

> [@Custom Homepage for Groups](https://meta.discourse.org/t/custom-homepage-for-groups/199623):
>
> Overview When installed and added to the active theme, this theme component enables you to control the ‘homepage’, allowing it to be different from the set of pages Discourse allows by default, as well as having different groups have different “homepages” (e.g., group members care only or mostly about a particular category). This can be for all users, anon (non-logged in), mobile users, or according to a user’s primary group. Initially developed by @pfaffman. See [User-specific Discourse home pag…](https://meta.discourse.org/t/user-specific-discourse-home-page/160229)

> [@Allow Arbitrary Homepage (by Jay Pfaffman)](https://meta.discourse.org/t/allow-arbitrary-homepage-by-jay-pfaffman/152459):
>
> Well, @hellekin thought that this deserved its own topic. I’m not quite sure it’s ready for such, but here it is. I’ll have a look at stuff early next week and try to make sure that it looks like something that other people could really use. wink As he said:

---

<div class="post-metadata">

### Author: ![Drew-ART](https://avatars.discourse-cdn.com/v4/letter/d/8edcca/32.png) [@Drew-ART](https://meta.discourse.org/u/Drew-ART)
#### Post date: [November 20, 2025, 12:33am UTC](https://meta.discourse.org/t/how-to-redirect-when-login/333296/3 "2025-11-20T00:33:15Z")

</div>

@blue-sky

I had a go at this. It should work for your use case.

[https://meta.discourse.org/t/login-redirect-and-or-group-page-banner-component/](https://meta.discourse.org/t/login-redirect-and-or-group-page-banner-component/)
