Atlas fails GitHub Copilot setup with Failed to initiate device authorization when the device-authorization request is not ok, and with Failed to fetch models: <status> when the Copilot model catalog throws the HTTP status returned by the models endpoint. The fix is to re-run `atlas auth login`, choose GitHub Copilot to restart the device flow, and confirm the GitHub account has an active Copilot subscription. A models fetch returning 401 or 403 means the Copilot token expired and you need to re-authenticate.
Why does Atlas say Failed to fetch models after Copilot login?
Atlas reports Failed to fetch models: <status> when the GitHub Copilot model catalog throws with the HTTP status returned by the models endpoint. A status of 401 or 403 means the Copilot token expired, so re-run `atlas auth login`, choose GitHub Copilot, and re-authenticate.
Failed to fetch models is a distinct failure from the device authorization failure, and the distinction matters. The device flow can complete successfully and store a token, and the model catalog request can still be rejected later. Atlas surfaces the raw HTTP status in the message precisely so you can tell those apart. A 401 or 403 in that message is an authentication problem, not a network problem, and the documented remedy is re-authentication. If the status is something else, the token is not necessarily stale, and network egress to the GitHub API host is the next thing to check.
Does an inactive Copilot subscription cause this Atlas error?
An inactive GitHub Copilot subscription is one of the four documented causes of Copilot setup failure in Atlas. Confirming the GitHub account has an active Copilot subscription is a required step, because the device flow can finish while the models endpoint still rejects the token with a 401 or 403.
Subscription state is easy to overlook because the Atlas error text names the technical failure, not the billing one. Failed to fetch models: 403 is what an unauthorized Copilot account looks like from inside Atlas. Check the subscription on the GitHub account you actually authorized, not the one you assume you used, since the device flow authorizes whichever account is signed in to the browser. Once the subscription is confirmed active, re-run `atlas auth login`, choose GitHub Copilot, and let the device flow issue a fresh token. Be honest with yourself here: Atlas cannot work around a lapsed subscription.
What if the Atlas Copilot device request never starts at all?
When the Atlas Copilot device request never starts, check network egress to the GitHub API host. The github-copilot plugin throws Failed to initiate device authorization the moment the device-authorization request is not ok, so a blocked outbound path in 2026 produces that error before any user code is ever displayed.
A blocked or proxied network path is the failure mode where retrying is pointless. If the Atlas process cannot reach the GitHub API host, the device-authorization request will keep coming back not ok, and the github-copilot plugin will keep throwing at the same point. Confirm outbound access from the exact machine running Atlas, not from a workstation on a different network segment. Corporate proxies and egress allowlists are the usual culprits. Once egress to the GitHub API host is confirmed, re-run `atlas auth login` and choose GitHub Copilot, and the device flow should issue a code normally.
How to verify the Copilot fix worked in Atlas
Verify the Atlas GitHub Copilot fix by running `atlas auth login` again, choosing GitHub Copilot, and completing the device flow with no Failed to initiate device authorization message. Then confirm the model catalog loads with no Failed to fetch models: 401 or 403, because both halves must be clean.
A successful verification has two halves, matching the two failures. First, the device flow completes and Atlas does not throw Failed to initiate device authorization. Second, the model catalog loads and Atlas does not throw Failed to fetch models: <status>. Only when both are clean is Copilot actually usable. Open the model switcher and confirm the Copilot models appear in the list. If the device flow succeeds but the catalog still fails with 401 or 403, the token is expired again or the GitHub account still lacks an active Copilot subscription, and the subscription is the thing to fix.
How to fix it
- 01Re-run `atlas auth login` and choose GitHub Copilot to restart the device flow.
- 02Complete the GitHub device authorization in the browser without closing the Atlas prompt.
- 03Confirm the GitHub account has an active Copilot subscription.
- 04If the models fetch returns 401 or 403, treat the Copilot token as expired and re-authenticate with `atlas auth login`.
- 05Check network egress to the GitHub API host if the device request never starts.
- 06Re-run the original Atlas command once the Copilot model list loads.
Frequently asked questions
- How do I fix Failed to initiate device authorization in Atlas?
- Re-run `atlas auth login` and choose GitHub Copilot to restart the device flow. The github-copilot plugin throws that error when the device-authorization request is not ok, so a fresh flow usually clears it. If the request never starts, check network egress to the GitHub API host.
- What does Failed to fetch models: 401 mean in Atlas Copilot?
- A models fetch returning 401 or 403 means the Copilot token expired. Re-authenticate by running `atlas auth login` and choosing GitHub Copilot. The Copilot model catalog in Atlas throws with the HTTP status when the models endpoint fails, which is why the status is printed in the message.
- Does Atlas Copilot require an active Copilot subscription?
- Yes. Confirming the GitHub account has an active Copilot subscription is a documented fix step for Atlas Copilot setup failures. The device flow can complete while the models endpoint still rejects the token, so a lapsed subscription surfaces as Failed to fetch models rather than as a login error.
- Why does Atlas Copilot auth fail behind a corporate proxy?
- If Atlas cannot reach the GitHub API host, the device-authorization request comes back not ok and the github-copilot plugin throws Failed to initiate device authorization. Check network egress to the GitHub API host from the machine running Atlas, then re-run `atlas auth login`.
- How do I re-authenticate GitHub Copilot in Atlas?
- Run `atlas auth login` and choose GitHub Copilot. That restarts the device flow and issues a fresh token, which is the documented remedy when the models fetch returns 401 or 403 and the Copilot token has expired.
- Is the Atlas Copilot device authorization error a config problem?
- No. The failure comes from the github-copilot plugin throwing when the device-authorization request is not ok, or from the model catalog throwing with the HTTP status when the models endpoint fails. Both are auth and network conditions, not Atlas config keys, so the fix is `atlas auth login`, not a config edit.
- How do I confirm Copilot is working again in Atlas?
- Complete `atlas auth login` with GitHub Copilot selected, then confirm the Copilot models load with no Failed to fetch models error. Atlas lets you switch the active model and provider on the fly with favorites and recents, so the Copilot models should appear in the switcher.
Try Atlas in your terminal
The terminal-native AI coding agent. Free core, single binary.
Install AtlasRelated guides
Atlas with Qwen3 32B (Ollama): dense reasoning over raw speed in 2026
Qwen3 32B (Ollama) in Atlas: dense 20GB weights on a 24GB card, 40K tokens (40,960) of context, Free (self-hosted). Slower than the MoE, steadier on hard problems.
Atlas with Llama 3.3 70B (local via Ollama) in 2026: Dense 70B on Your Own Hardware
Llama 3.3 70B (local via Ollama) drives Atlas at 128K tokens (131,072) and Free (self-hosted) pricing, with a $0.59 / $0.79 per Mtok Groq fallback on identical weights.
Write Unit Tests for Untested Code with Atlas in 2026
How to write unit tests for untested code with Atlas in 2026: the lsp tool enumerates exported symbols, grep copies repo conventions, and bash actually runs the suite.
Atlas for Dart in 2026
Adopt Atlas, the terminal-native AI coding agent, for Dart development in 2026. Enhance productivity with intelligent code search, refactoring, and robust safety features across your Dart projects.
Atlas with GPT-4.1 mini (2026): The Cheap Slot That Still Holds a Million Tokens
GPT-4.1 mini gives Atlas a 1,047,576 token context at $0.40 per Mtok input and $1.60 per Mtok output. The right small_model when your cheap slot needs a huge window.
Debug a Single Failing Test with Atlas in 2026
How to debug one failing test with Atlas in 2026: run it in isolation with bash, walk the call graph with the lsp tool, and fix the code, not the assertion.
Atlas for SolidJS: A Terminal-Native AI Coding Agent Built on Solid, for Solid, in 2026
Atlas is a terminal-native AI coding agent for SolidJS in 2026. It reads your createSignal and createMemo graph, fixes destructured props that break reactivity, and runs vitest.
Atlas vs Windsurf: Terminal AI Coding Agents in 2026
Atlas and Windsurf offer distinct AI coding experiences in 2026. Atlas provides a terminal-native TUI with permission-gated tools, while Windsurf features an in-editor live preview and a dedicated GUI.