Replit.dev and Google OAuth

Hi all,

So I’ve been developing against Google’s Oauth using the cloud console - all was fine and dandy until the changes to hosting which meant that my dev URL now changes constantly.

The reason this is an issue is that building against this authentication system involves telling Google the JavaScript origins and Redirect URLs that your auth is using. These are no longer predictable and you cannot use wildcards as a option to whitelist the entire replitl.dev domain.

Is there either a way around this?
Can I add a static dev domain that I already own for these purposes?
Is there any predictable URL I can use?

Please note that I do not require the old style repl.co links - or hosting to be always on for the development server - just a predictable URL whilst the development is happening. Using deployments for testing is not an option as this would slow development down to painful levels.

1 Like

The new dev URL should only change ~once a year. It’s always in this format

<repl-id>-00-<characters>.<repl-cluster>.replit.dev
(<characters> being what changes)

5 Likes

I’m not sure it does stay static - mine has definitely changed after a period of inactivity as all my test windows stopped responding and I even had to restart the repl to get the dev server working again - is this documented anywhere?

4 Likes

I don’t think so, but it was confirmed by Ray:

3 Likes

I believe there is some information r.e. this somewhere here: https://docs.replit.com/hosting/deployments/troubleshooting

4 Likes

Thanks :pray:
I have seen my replit.dev url change and I’m not moving anything between clusters.
Would love it if we could slap a custom domain on the replit.dev url though, would solve a lot of problems.

5 Likes

Feature Requests

3 Likes