Meteor OAuth callback URL problems with custom domain on Heroku


TLDR; I have this exact problem

Long Version
I have setup custom domain on heroku for my app.
Usually user visits my domain and clicks “Sign in with Google”

  1. Google authenticates and calls back to
  2. The popup closes and the user is now authenticated on

Instead, at step 2, Google is calling back to The upshot is I can’t log in at I can go to and that works properly.

As mentioned in the answer from above link, I tried to set ROOT_URL with Meteor.absoluteUrl(''); on server’s startup method but still no luck!

Any help? Thanks in Advance.


Figured out a workaround. I manually changed the ROOT_URL value from console to Earlier it was

p.s: yes, now the login functionality on is broken!