Solving the Antigravity Authentication Redirect Loop on Windows

Published: (March 9, 2026 at 12:41 PM EDT)
1 min read
Source: Dev.to

Source: Dev.to

Cover image for Solving the Antigravity Authentication Redirect Loop on Windows

Why this happens

This usually occurs because the underlying gaxios library in the Antigravity build is strictly enforcing TLS/SSL verification. In certain Windows network configurations, this handshake fails during the local callback, preventing the Authorization Code from being swapped for an Access Token.

The Step-by-Step Fix

Step 1: Locate the Source File

Open File Explorer and navigate to the local installation directory of the app:

C:\Users\<YourUserName>\AppData\Local\Programs\Antigravity\resources\app\node_modules\gaxios\build\cjs\src\

Step 2: Modify gaxios.js

Open gaxios.js in your preferred text editor.

  1. Find the HTTPS requirement line:
const https_1 = require("https");
  1. Add the following bypass immediately after it:
process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0";

Step 3: Restart and Authenticate

Save the file and restart your Antigravity client. When you click Sign in with Google this time, the app will successfully capture the redirect from your browser.

0 views
Back to Blog

Related posts

Read more »

Authentication vs Authorization

Authentication Authentication is about confirming a user's identity. It is the process the system uses to verify that you are who you claim to be. A common exa...