How to Use Claude Opus 4.5 & Gemini 3 for Free with OpenCode

Published: (January 13, 2026 at 02:14 AM EST)
2 min read
Source: Dev.to

Source: Dev.to

TL;DR

OpenCode is an open‑source AI coding agent that can connect to models such as Claude, GPT, Gemini, and more. It includes free models out of the box, or you can bring your own from any provider. This guide shows how to set up OpenCode with Antigravity Auth using Google OAuth.

Installation

You can install OpenCode with many package managers (Homebrew, npm, pnpm, yarn, scoop, choco, etc.). The example below uses bun:

bun install -g opencode-ai

For additional install options, see the Installation Docs.

Authentication (Antigravity Auth)

  1. Install the opencode-antigravity-auth plugin. The repository is available at . Follow the install instructions in the repo and choose Option B (manual config).

  2. Edit the OpenCode configuration file to add the plugin:

    vim ~/.config/opencode/opencode.json
    {
      "plugin": ["opencode-antigravity-auth@beta"]
    }
  3. Ensure you have a Google account that supports Antigravity.

  4. Run the authentication command:

    opencode auth login
  5. You’ll see a provider list. Select Google, then choose OAuth with Google (Antigravity). Your browser will open; sign in with your Google account. After a successful login you should see messages similar to:

    •  Multi-account setup complete (1 account(s)).
    o  Login successful
    —  Done

Configuration

Open the full configuration file to add model definitions:

vim ~/.config/opencode/opencode.json

Paste the configuration block from the plugin’s documentation (you can keep the version you added earlier unless you want to customize models). Save and exit.

Using OpenCode

Start OpenCode:

opencode

In the UI, press Ctrl + P, then select:

Switch model → Claude Opus 4.5 (Antigravity)

You’re now ready to code with OpenCode using Antigravity‑authenticated models. Happy coding! 🌱

Back to Blog

Related posts

Read more »

𝗗𝗲𝘀𝗶𝗴𝗻𝗲𝗱 𝗮 𝗣𝗿𝗼𝗱𝘂𝗰𝘁𝗶𝗼𝗻‑𝗥𝗲𝗮𝗱𝘆 𝗠𝘂𝗹𝘁𝗶‑𝗥𝗲𝗴𝗶𝗼𝗻 𝗔𝗪𝗦 𝗔𝗿𝗰𝗵𝗶𝘁𝗲𝗰𝘁𝘂𝗿𝗲 𝗘𝗞𝗦 | 𝗖𝗜/𝗖𝗗 | 𝗖𝗮𝗻𝗮𝗿𝘆 𝗗𝗲𝗽𝗹𝗼𝘆𝗺𝗲𝗻𝘁𝘀 | 𝗗𝗥 𝗙𝗮𝗶𝗹𝗼𝘃𝗲𝗿

!Architecture Diagramhttps://dev-to-uploads.s3.amazonaws.com/uploads/articles/p20jqk5gukphtqbsnftb.gif I designed a production‑grade multi‑region AWS architectu...