"Authentication fails on Linux - token exchange not completing"
Before opening, please confirm:
- [x] I have searched for duplicate or closed issues
Operating System
Kubuntu 24.04
Kiro Version
kiro-ide-0.6.32-stable-linux-x64
Bug Description
When trying to authenticate Kiro opens up the browser and when authenticating it hangs on "URL handler". Tried all suggested fixes but nothing worked.
Logs suggest " 2025-12-01 09:33:55.023 [error] MISSING_TOKEN: No valid token found 2025-12-01 09:33:55.351 [error] Failed to retrieve auth token: No valid token found" .
Steps to Reproduce
Tried everything that was suggested here: https://github.com/kirodotdev/Kiro/issues/3782#issuecomment-3564488212 Tried debugging with all AI tools to no avail.
Expected Behavior
Authenticate and open the IDE successfully
Conversation ID
No response
Additional Context
No response
Also experiencing this on Manjaro KDE
Environment:
- OS: Manjaro Linux (Kernel 6.12.48-1-MANJARO)
- Desktop: KDE Plasma
- Kiro Version: 0.7.21-stable-linux-x64
Same symptoms:
- OAuth completes in browser successfully
- Browser redirects to
kiro://kiro.kiroagent/authenticate-success?code=...&state=... - Extension host crashes with
MISSING_TOKEN: No valid token found - Second splash screen appears showing only "Cancel" button - no way to proceed
Both Google AND GitHub authentication fail identically.
Additional debugging performed:
- Verified URL handler IS being called correctly (confirmed via debug logs)
- Created proper
.desktopfile withx-scheme-handler/kiro - Registered with
xdg-mimeand KDE protocol handler - Tested with
--open-urlflag - Tried opening workspace before authentication (
kiro ~/kiro-workspace)
Full error logs from ~/.config/Kiro/logs/*/window1/exthost/exthost.log:
[error] MISSING_TOKEN: No valid token found
[error] CodeExpectedError: Unable to write to Workspace Settings because no workspace is opened.
[info] Extension host terminating: renderer closed the MessagePort
[info] Extension host with pid XXXXX exiting with code 0
Console output:
[main 2025-12-06T07:32:11.709Z] update#setState idle
libva error: /usr/lib/dri/i965_drv_video.so init failed
[main 2025-12-06T07:32:27.653Z] Extension host with pid 1096200 exited with code: 0, signal: unknown.
[main 2025-12-06T07:32:27.685Z] [UtilityProcess id: 1, type: fileWatcher, pid: 1096289]: crashed with code 15 and reason 'killed'
Root cause: The kiro:// URL handler works correctly, but Kiro's extension host fails to process the OAuth callback token on KDE-based Linux distributions.
This is a CRITICAL blocker - completely unable to use Kiro on this system.
✅ WORKAROUND FOUND!
Solution: Use "Sign in with AWS Builder ID" instead of direct Google/GitHub OAuth.
Steps:
- On Kiro's authentication splash screen, select "Sign in with AWS Builder ID" (instead of Google/GitHub)
- In the browser, authenticate to AWS (you can use Google to sign in to AWS)
- AWS redirects back to Kiro successfully
- Authentication completes! ✅
This bypasses the broken direct OAuth flow on Linux and works perfectly.
The direct Google/GitHub OAuth is still broken and should be fixed, but this workaround allows Linux users to use Kiro in the meantime.
Correction: This affects multiple Linux distributions and desktop environments, not just KDE. Similar issues reported on:
- Kubuntu (KDE)
- Manjaro (KDE)
- Fedora (GNOME)
- Linux Mint (Cinnamon)
The issue appears to be a broader Linux OAuth callback handling problem in Kiro's extension host.
✅ WORKAROUND FOUND!
Solution: Use "Sign in with AWS Builder ID" instead of direct Google/GitHub OAuth.
Steps:
- On Kiro's authentication splash screen, select "Sign in with AWS Builder ID" (instead of Google/GitHub)
- In the browser, authenticate to AWS (you can use Google to sign in to AWS)
- AWS redirects back to Kiro successfully
- Authentication completes! ✅
This bypasses the broken direct OAuth flow on Linux and works perfectly.
The direct Google/GitHub OAuth is still broken and should be fixed, but this workaround allows Linux users to use Kiro in the meantime.
![]()
Yep, that actually worked. Too bad the others didn't and on so many platforms.
Hi @mikiedelsteinspiral , are you still unable to log in with Google/GitHub on Linux? If so, can you please let me know if you are installing the linux .deb file or running Kiro from the standalone .tar.gz file?
awchristou Arch Linux It doesn't matter if it's aur kiro-ide or standalone.tar.gz I can only log in with my AWS Builder ID, but I lost my paid credits (960) and got 500 back in the free plan.
Hi,
I had the same issue in Kubuntu and Aurora Linus (Fedora Kinoite).
In my case Kiro was trying to open a xdg-open callback, which failed.
I did the following and managed to login using Google in Aurora (Fedora). I have not yet tried this in Kubuntu.
- Create a
~/.local/share/applications/kiro.desktop:
[Desktop Entry]
Type=Application
Name=Kiro
Exec=/var/home/daco/Downloads/Kiro/kiro --open-url %u
MimeType=x-scheme-handler/kiro;
NoDisplay=true
Terminal=false
StartupNotify=false
Change /var/home/daco/Downloads/Kiro/kiro with the path to your bin. In this case I just downloaded the tar.gz from kiro.dev and extracted it to my Download Folder.
The important part is --open-url %u
Then run
update-desktop-database ~/.local/share/applications/
After that I started Kiro, used the Google Button to login, and it asked to open the XDG-OPEN, and it worked.
I hope that helps!
https://github.com/kirodotdev/Kiro/issues/4130#issuecomment-3647604386
It doesn't work, I can still only log in with my AWS Builder ID, but I don't see my subscription credits there. I got 500 credits again as a free user. I have 2 desktop files: kiro-url-handler.desktop kiro.desktop These seem to work fine.
Hi @mikiedelsteinspiral , are you still unable to log in with Google/GitHub on Linux? If so, can you please let me know if you are installing the linux .deb file or running Kiro from the standalone .tar.gz file?
Hi, still and with both installations.
thanks @dacog ,it works on fedora 43(kde), don't use chrome(dosn't work),use firefox
In KDE Plasma environment, additional configuration steps are required to make custom URL protocols work properly. Here's the complete solution for KDE:
1. Create the .desktop file (same as before)
mkdir -p ~/.local/share/applications
nano ~/.local/share/applications/kiro.desktop
Content:
[Desktop Entry]
Type=Application
Name=Kiro
Exec=/var/home/daco/Downloads/Kiro/kiro --open-url %u
MimeType=x-scheme-handler/kiro;
Terminal=false
StartupNotify=false
Note: Modify the Exec path to match your actual Kiro executable path
2. Update desktop database
update-desktop-database ~/.local/share/applications/
3. KDE-specific configuration - Register protocol handler
In KDE, additional protocol association configuration is needed. Edit the following file:
nano ~/.config/kioslaverc
Add the following content:
[Protocol Settings]
kiro=kiro
4. KDE-specific configuration - MIME type association
Create the MIME type configuration file:
mkdir -p ~/.local/share/mime/packages
nano ~/.local/share/mime/packages/kiro.xml
Content:
<?xml version="1.0" encoding="UTF-8"?>
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
<mime-type type="x-scheme-handler/kiro">
<comment>Kiro Protocol Handler</comment>
</mime-type>
</mime-info>
Then update the MIME database:
update-mime-database ~/.local/share/mime
5. KDE-specific configuration - Default applications
Configure manually in KDE System Settings:
- Open "System Settings" → "Applications" → "Default Applications"
- Find the "URI Associations" or "Protocol Associations" section
- Search for "kiro" protocol
- Select "kiro.desktop" as the handler
Or use the command line:
kwriteconfig5 --file kdeglobals --group "General" --key "BrowserApplication" "kiro.desktop"
6. Verify KDE protocol handling
In KDE, you can test protocol handling using kioclient5:
kioclient5 exec "kiro://test"
7. If it still fails - Check KDE service menu
Sometimes KDE ignores the NoDisplay=true setting. Try removing that line:
[Desktop Entry]
Type=Application
Name=Kiro
Exec=/var/home/daco/Downloads/Kiro/kiro --open-url %u
MimeType=x-scheme-handler/kiro;
Terminal=false
StartupNotify=false
8. Final verification steps
- Restart KDE session (log out and back in)
- Test in terminal:
xdg-open "kiro://test" kioclient5 exec "kiro://test" - Try Kiro login
Important notes
- KDE's protocol handling is stricter than GNOME and requires complete MIME type registration
- Ensure the Kiro application path is correct and has execute permissions
- If using Flatpak or Snap installed browsers, additional permission configuration may be needed
- In KDE,
kioclient5is the standard tool for handling URLs and is more reliable than xdg-open
If the above steps still don't resolve the issue, check Kio logs:
journalctl -f | grep -i kio
KDE environment typically requires more detailed protocol registration configuration than other desktop environments because its components (KIO slaves) have their own independent protocol handling mechanisms.
Hi,
I had the same issue in Kubuntu and Aurora Linus (Fedora Kinoite).
In my case Kiro was trying to open a xdg-open callback, which failed.
I did the following and managed to login using Google in Aurora (Fedora). I have not yet tried this in Kubuntu.
- Create a
~/.local/share/applications/kiro.desktop:[Desktop Entry] Type=Application Name=Kiro Exec=/var/home/daco/Downloads/Kiro/kiro --open-url %u MimeType=x-scheme-handler/kiro; NoDisplay=true Terminal=false StartupNotify=falseChange
/var/home/daco/Downloads/Kiro/kirowith the path to your bin. In this case I just downloaded the tar.gz from kiro.dev and extracted it to my Download Folder.The important part is
--open-url %uThen run
update-desktop-database ~/.local/share/applications/ After that I started Kiro, used the Google Button to login, and it asked to open the XDG-OPEN, and it worked.
I hope that helps!
it works on fedora 43(kde), don't use chrome(dosn't work),use firefox
This, I finally I got it working with Firefox
https://github.com/kirodotdev/Kiro/issues/4130#issuecomment-3619706102
Using the "Sign in with AWS Builder ID" solved it for me as well, but it a far from ideal. For testing Kiro it is sufficient for now, but as soon as I need to switch to a pro account, my employer isn't likely to accept this...
I am on Arch Linux / KDE
Hi, this Linux OAuth deep-link issue has been addressed. CLI 2.1 (Apr 24, 2026) introduced Device Flow authentication which works on all Linux environments without requiring the kiro: URI scheme or browser deep-linking.
Run kiro-cli login and it will display a URL + one-time code you can enter in any browser. See: https://kiro.dev/docs/cli/authentication/#device-flow-recommended
For the IDE, subsequent releases (0.9+) also improved OAuth handling. If you're still experiencing issues on the latest version, please open a new issue.
Closing as resolved.