[GH-ISSUE #3376] [bug]: Unable to log in #1126

Open
opened 2026-03-16 18:45:01 +03:00 by kerem · 30 comments
Owner

Originally created by @mgmorcos on GitHub (Sep 21, 2023).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3376

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

I have configured Google SSO. When I press the login button, and sign in with my Google account, I expect to be logged in to Hoppscotch. This has only worked one time. The rest of the time I am either taken back to the home screen and still not logged in, or I get an Unauthorized 401 error from the API. I am using the latest version of the AIO image with Docker Compose.

Steps to reproduce

  1. Configure Google SSO in .env
  2. Start Hoppscotch (db, api, front-end)
  3. Press Login button
  4. Sign in to Google account

Environment

Production

Version

Self-hosted

Originally created by @mgmorcos on GitHub (Sep 21, 2023). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3376 ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current behavior I have configured Google SSO. When I press the login button, and sign in with my Google account, I expect to be logged in to Hoppscotch. This has only worked one time. The rest of the time I am either taken back to the home screen and still not logged in, or I get an Unauthorized 401 error from the API. I am using the latest version of the AIO image with Docker Compose. ### Steps to reproduce 1. Configure Google SSO in `.env` 2. Start Hoppscotch (db, api, front-end) 3. Press Login button 4. Sign in to Google account ### Environment Production ### Version Self-hosted
Author
Owner

@mgmorcos commented on GitHub (Sep 21, 2023):

Clearing cookies resolves the issue. Clearing cookies is necessary every time the server is restarted. Is there a way to invalidate sessions on the server side, so less technical users don't need to be asked to clear cookies?

<!-- gh-comment-id:1728834054 --> @mgmorcos commented on GitHub (Sep 21, 2023): Clearing cookies resolves the issue. Clearing cookies is necessary every time the server is restarted. Is there a way to invalidate sessions on the server side, so less technical users don't need to be asked to clear cookies?
Author
Owner

@mgmorcos commented on GitHub (Sep 21, 2023):

So far the best option I have found is to change the session secret before every server restart. Then login works fine.

<!-- gh-comment-id:1728845706 --> @mgmorcos commented on GitHub (Sep 21, 2023): So far the best option I have found is to change the session secret before every server restart. Then login works fine.
Author
Owner

@balub commented on GitHub (Sep 21, 2023):

@mgmorcos if the issue still persists, could you share the backend logs when the error happens?

<!-- gh-comment-id:1728961577 --> @balub commented on GitHub (Sep 21, 2023): @mgmorcos if the issue still persists, could you share the backend logs when the error happens?
Author
Owner

@jacoatvatfree commented on GitHub (Sep 22, 2023):

I'm seeing the same behaviour, till now I had to clear site data (in browser application storage). But I will try changing the session secret before reboot as suggested above.

<!-- gh-comment-id:1731111246 --> @jacoatvatfree commented on GitHub (Sep 22, 2023): I'm seeing the same behaviour, till now I had to clear site data (in browser application storage). But I will try changing the session secret before reboot as suggested above.
Author
Owner

@mgmorcos commented on GitHub (Sep 26, 2023):

The logs are silent when login issues occur. The secret reset is not sufficient for all cases, sometimes clearing LocalStorage is also needed.

<!-- gh-comment-id:1734719392 --> @mgmorcos commented on GitHub (Sep 26, 2023): The logs are silent when login issues occur. The secret reset is not sufficient for all cases, sometimes clearing LocalStorage is also needed.
Author
Owner

@dsole commented on GitHub (Oct 3, 2023):

This could be related or duplicate of #3315

<!-- gh-comment-id:1745785158 --> @dsole commented on GitHub (Oct 3, 2023): This could be related or duplicate of #3315
Author
Owner

@mgmorcos commented on GitHub (Oct 3, 2023):

My setup is on a single node without load balancing or clustering.

<!-- gh-comment-id:1745841767 --> @mgmorcos commented on GitHub (Oct 3, 2023): My setup is on a single node without load balancing or clustering.
Author
Owner

@dsole commented on GitHub (Oct 4, 2023):

I was mainly thinking that even in a single node environment, when the server restarts it will be clearing the server's memory-based session store, so your cookie won't match a session anymore and needs to be cleared.

So the problem of the session being memory-based rather than a persistent method was how they're potentially related.

<!-- gh-comment-id:1746480216 --> @dsole commented on GitHub (Oct 4, 2023): I was mainly thinking that even in a single node environment, when the server restarts it will be clearing the server's memory-based session store, so your cookie won't match a session anymore and needs to be cleared. So the problem of the session being memory-based rather than a persistent method was how they're potentially related.
Author
Owner

@skywsp commented on GitHub (Oct 8, 2023):

@dsole When I sign in with eamil, I got the same problem, and clearn cookies not working, what shoud I do...

image

<!-- gh-comment-id:1751955929 --> @skywsp commented on GitHub (Oct 8, 2023): @dsole When I sign in with eamil, I got the same problem, and clearn cookies not working, what shoud I do... ![image](https://github.com/hoppscotch/hoppscotch/assets/25943305/665f626f-66c6-460a-b237-00b53705c890)
Author
Owner

@Bhupendrsingh commented on GitHub (Nov 2, 2023):

@dsole When I sign in with eamil, I got the same problem, and clearn cookies not working, what shoud I do...

image

Hi
i am also facing the same issue , are you able to resolve this

<!-- gh-comment-id:1790413214 --> @Bhupendrsingh commented on GitHub (Nov 2, 2023): > @dsole When I sign in with eamil, I got the same problem, and clearn cookies not working, what shoud I do... > > ![image](https://user-images.githubusercontent.com/25943305/273434399-665f626f-66c6-460a-b237-00b53705c890.png) Hi i am also facing the same issue , are you able to resolve this
Author
Owner

@SeptianENC commented on GitHub (Dec 19, 2023):

I have same problem, when i click magic link the browser just refresh but i'm still not login.
does anyone have solution?

<!-- gh-comment-id:1862238099 --> @SeptianENC commented on GitHub (Dec 19, 2023): I have same problem, when i click magic link the browser just refresh but i'm still not login. does anyone have solution?
Author
Owner

@pravindodia commented on GitHub (Feb 11, 2024):

+1 for Email Auth Provider

<!-- gh-comment-id:1937784193 --> @pravindodia commented on GitHub (Feb 11, 2024): +1 for Email Auth Provider
Author
Owner

@carsonbird commented on GitHub (Mar 10, 2024):

So, is the impact of this bug that it is currently impossible to log in to the desktop app? Since at least September '23? I'm on Linux and I've attempted both Email Auth and Github Auth.

<!-- gh-comment-id:1987314874 --> @carsonbird commented on GitHub (Mar 10, 2024): So, is the impact of this bug that it is currently impossible to log in to the desktop app? Since at least September '23? I'm on Linux and I've attempted both Email Auth and Github Auth.
Author
Owner

@fscaptain commented on GitHub (Mar 17, 2024):

+1

<!-- gh-comment-id:2002629395 --> @fscaptain commented on GitHub (Mar 17, 2024): +1
Author
Owner

@Teznew commented on GitHub (Mar 20, 2024):

+1

<!-- gh-comment-id:2009018921 --> @Teznew commented on GitHub (Mar 20, 2024): +1
Author
Owner

@pravindodia commented on GitHub (Mar 20, 2024):

Please change your enpoints for all from http to https and the login will work fine, its not mentioned in any document but I managed to login with it and it works 100%.

<!-- gh-comment-id:2009029625 --> @pravindodia commented on GitHub (Mar 20, 2024): Please change your enpoints for all from http to https and the login will work fine, its not mentioned in any document but I managed to login with it and it works 100%.
Author
Owner

@carsonbird commented on GitHub (Mar 24, 2024):

Hmm. Tried this, still didn't work. What authentication provider are you using (email, Google, GitHub, etc)?

<!-- gh-comment-id:2016864323 --> @carsonbird commented on GitHub (Mar 24, 2024): Hmm. Tried this, still didn't work. What authentication provider are you using (email, Google, GitHub, etc)?
Author
Owner

@pravindodia commented on GitHub (Mar 26, 2024):

Hmm. Tried this, still didn't work. What authentication provider are you using (email, Google, GitHub, etc)?

I am using email authentication provider,
Are you behind proxy, or are you using ssl directly , because if you are directly using ssl then you have to make sure you have proper ssl ceritficates.
Try to inspect the login response and and log in hopscotch and see what eact error are you getting.
My issue was resolved after adding ssl.

<!-- gh-comment-id:2019804968 --> @pravindodia commented on GitHub (Mar 26, 2024): > Hmm. Tried this, still didn't work. What authentication provider are you using (email, Google, GitHub, etc)? I am using email authentication provider, Are you behind proxy, or are you using ssl directly , because if you are directly using ssl then you have to make sure you have proper ssl ceritficates. Try to inspect the login response and and log in hopscotch and see what eact error are you getting. My issue was resolved after adding ssl.
Author
Owner

@carsonbird commented on GitHub (Mar 30, 2024):

@pravindodia nope, no proxy. Tried both methods with and without TLS, neither worked.

<!-- gh-comment-id:2028099170 --> @carsonbird commented on GitHub (Mar 30, 2024): @pravindodia nope, no proxy. Tried both methods with and without TLS, neither worked.
Author
Owner

@pravindodia commented on GitHub (Mar 30, 2024):

@pravindodia nope, no proxy. Tried both methods with and without TLS, neither worked.

Can you check the logs also see what error log you are getting ?

<!-- gh-comment-id:2028103475 --> @pravindodia commented on GitHub (Mar 30, 2024): > @pravindodia nope, no proxy. Tried both methods with and without TLS, neither worked. Can you check the logs also see what error log you are getting ?
Author
Owner

@carsonbird commented on GitHub (Mar 30, 2024):

Can you check the logs also see what error log you are getting ?

@pravindodia no errors in the console :p

<!-- gh-comment-id:2028442769 --> @carsonbird commented on GitHub (Mar 30, 2024): > Can you check the logs also see what error log you are getting ? @pravindodia no errors in the console :p
Author
Owner

@pravindodia commented on GitHub (Mar 30, 2024):

Can you check the logs also see what error log you are getting ?

@pravindodia no errors in the console :p

@carsonbird What about browser network requests and responses?

<!-- gh-comment-id:2028443270 --> @pravindodia commented on GitHub (Mar 30, 2024): > > Can you check the logs also see what error log you are getting ? > > @pravindodia no errors in the console :p @carsonbird What about browser network requests and responses?
Author
Owner

@CharkiAbdelillah commented on GitHub (Apr 10, 2024):

@pravindodia hey can you help me pls

<!-- gh-comment-id:2048489675 --> @CharkiAbdelillah commented on GitHub (Apr 10, 2024): @pravindodia hey can you help me pls
Author
Owner

@pravindodia commented on GitHub (Apr 11, 2024):

@pravindodia hey can you help me pls

@CharkiAbdelillah what's your issue?

<!-- gh-comment-id:2048805352 --> @pravindodia commented on GitHub (Apr 11, 2024): > @pravindodia hey can you help me pls @CharkiAbdelillah what's your issue?
Author
Owner

@mohijeet-changejar commented on GitHub (Dec 8, 2024):

is there any workaround? i am still facing same issue it works fine with clearing cookies but not in first attempt, it shows 404 error page like its requesting content that does not exits but when i clear cache and reload page it logged me in.

<!-- gh-comment-id:2526183902 --> @mohijeet-changejar commented on GitHub (Dec 8, 2024): is there any workaround? i am still facing same issue it works fine with clearing cookies but not in first attempt, it shows 404 error page like its requesting content that does not exits but when i clear cache and reload page it logged me in.
Author
Owner

@Hopp-magis commented on GitHub (Jan 6, 2025):

Hello ! I need help too! I can't sign in i get this {"statusCode":500,"message":"Internal server error"}

<!-- gh-comment-id:2573179372 --> @Hopp-magis commented on GitHub (Jan 6, 2025): Hello ! I need help too! I can't sign in i get this {"statusCode":500,"message":"Internal server error"}
Author
Owner

@gh0st-offsec commented on GitHub (Mar 5, 2025):

So what's the solution for this? I've this issue....

<!-- gh-comment-id:2700329612 --> @gh0st-offsec commented on GitHub (Mar 5, 2025): So what's the solution for this? I've this issue....
Author
Owner

@abdul-musawwir002 commented on GitHub (Apr 10, 2025):

Hello ! I need help too! I can't sign in i get this {"statusCode":500,"message":"Internal server error"}

Hello @Hopp-magis I have the same issue. Did your issue got resolved?

<!-- gh-comment-id:2793611817 --> @abdul-musawwir002 commented on GitHub (Apr 10, 2025): > Hello ! I need help too! I can't sign in i get this {"statusCode":500,"message":"Internal server error"} Hello @Hopp-magis I have the same issue. Did your issue got resolved?
Author
Owner

@nooodream commented on GitHub (Jul 25, 2025):

i face the same issue,i use email and http to login, but when i click the email link, it not login in and let me send magic link again

<!-- gh-comment-id:3117193546 --> @nooodream commented on GitHub (Jul 25, 2025): i face the same issue,i use email and http to login, but when i click the email link, it not login in and let me send magic link again
Author
Owner

@Hopp-magis commented on GitHub (Aug 1, 2025):

let's check your env file

On Fri, Jul 25, 2025 at 12:14 PM nooodream @.***> wrote:

nooodream left a comment (hoppscotch/hoppscotch#3376)
https://github.com/hoppscotch/hoppscotch/issues/3376#issuecomment-3117193546

i face the same issue,i use email and http to login, but when i click the
email link, it not login in and let me send magic link again


Reply to this email directly, view it on GitHub
https://github.com/hoppscotch/hoppscotch/issues/3376#issuecomment-3117193546,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/BOFY7NKLCS47KTHYZ2WGS333KH7RDAVCNFSM6AAAAABTHKQWJGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTCMJXGE4TGNJUGY
.
You are receiving this because you were mentioned.Message ID:
@.***>

<!-- gh-comment-id:3144050111 --> @Hopp-magis commented on GitHub (Aug 1, 2025): let's check your env file On Fri, Jul 25, 2025 at 12:14 PM nooodream ***@***.***> wrote: > *nooodream* left a comment (hoppscotch/hoppscotch#3376) > <https://github.com/hoppscotch/hoppscotch/issues/3376#issuecomment-3117193546> > > i face the same issue,i use email and http to login, but when i click the > email link, it not login in and let me send magic link again > > — > Reply to this email directly, view it on GitHub > <https://github.com/hoppscotch/hoppscotch/issues/3376#issuecomment-3117193546>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/BOFY7NKLCS47KTHYZ2WGS333KH7RDAVCNFSM6AAAAABTHKQWJGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTCMJXGE4TGNJUGY> > . > You are receiving this because you were mentioned.Message ID: > ***@***.***> >
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1126
No description provided.