[GH-ISSUE #7021] Authentication deeplink flow for the macOS desktop application. #19335

Open
opened 2026-04-15 18:17:06 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @Nishchit14 on GitHub (Dec 27, 2025).
Original GitHub issue: https://github.com/better-auth/better-auth/issues/7021

Is this suited for github?

  • Yes, this is suited for github

I am currently building a macOS desktop application and want to implement the Google Sign‑In authentication flow. Authentication will occur through the browser. Once authentication is complete, it will redirect to the callback URL, which includes the deeplink for the desktop application to get redirect and open the app.

This is how I want to implement it, but I cannot find any example or related solution in the documentation. If this feature is available, please share the reference; otherwise, clearer guidance for this specific use case would be appreciated.

Describe the solution you'd like

There should be a working example, a demo, or at least a specific section describing how it works in the documentation for desktop/mobile app deeplink auth flow.

Describe alternatives you've considered

I haven't discovered any alternative yet. I think there should be native functionality, properly implemented for authentication.

Additional context

No response

Originally created by @Nishchit14 on GitHub (Dec 27, 2025). Original GitHub issue: https://github.com/better-auth/better-auth/issues/7021 ### Is this suited for github? - [x] Yes, this is suited for github ### Is your feature request related to a problem? Please describe. I am currently building a macOS desktop application and want to implement the Google Sign‑In authentication flow. Authentication will occur through the browser. Once authentication is complete, it will redirect to the callback URL, which includes the deeplink for the desktop application to get redirect and open the app. This is how I want to implement it, but I cannot find any example or related solution in the documentation. If this feature is available, please share the reference; otherwise, clearer guidance for this specific use case would be appreciated. ### Describe the solution you'd like There should be a working example, a demo, or at least a specific section describing how it works in the documentation for desktop/mobile app deeplink auth flow. ### Describe alternatives you've considered I haven't discovered any alternative yet. I think there should be native functionality, properly implemented for authentication. ### Additional context _No response_
GiteaMirror added the platformoauth labels 2026-04-15 18:17:06 -05:00
Author
Owner

@better-auth-agent[bot] commented on GitHub (Dec 27, 2025):

To implement the deeplink authentication flow for your macOS desktop application with Google Sign-In using Better Auth, first ensure you have the proper configuration in place. Here are the steps you should follow:

  1. Set Up Deeplink Configuration: Make sure your application's URL scheme is registered properly in both your app's settings and the Better Auth configuration. You can define the trustedOrigins in your Better Auth configuration to include your app’s deeplink URL.

  2. Handling Authentication: When authentication occurs through the browser, configure the Google Sign-In to redirect to your defined callback URL, which can include the deeplink back to your app.

  3. Access Session on Redirect: After the successful authentication, ensure that your app can extract any relevant authentication details from the URL passed back from Google Sign-In.

  4. Check Documentation or Examples: While there might not be specific examples in the documentation yet for your exact use case, there are discussions around handling OAuth flows that involve deeplinking [1].

  5. Request Features: If you require additional features or clearer examples, consider submitting a feature request for a more detailed guide on implementing deeplink auth flows for desktop applications.

Feel free to tag @better-auth-agent if you would like more specialized help on this! Is there any specific part of the implementation you'd like more guidance on?

If you need more help, tag @better-auth-agent in a comment so I can respond.

DiagramDiscordGitHub

Diagram Join Star

<!-- gh-comment-id:3693926841 --> @better-auth-agent[bot] commented on GitHub (Dec 27, 2025): To implement the deeplink authentication flow for your macOS desktop application with Google Sign-In using Better Auth, first ensure you have the proper configuration in place. Here are the steps you should follow: 1. **Set Up Deeplink Configuration**: Make sure your application's URL scheme is registered properly in both your app's settings and the Better Auth configuration. You can define the `trustedOrigins` in your Better Auth configuration to include your app’s deeplink URL. 2. **Handling Authentication**: When authentication occurs through the browser, configure the Google Sign-In to redirect to your defined callback URL, which can include the deeplink back to your app. 3. **Access Session on Redirect**: After the successful authentication, ensure that your app can extract any relevant authentication details from the URL passed back from Google Sign-In. 4. **Check Documentation or Examples**: While there might not be specific examples in the documentation yet for your exact use case, there are discussions around handling OAuth flows that involve deeplinking [[1]](https://github.com/better-auth/better-auth/issues/6936). 5. **Request Features**: If you require additional features or clearer examples, consider submitting a feature request for a more detailed guide on implementing deeplink auth flows for desktop applications. Feel free to tag @better-auth-agent if you would like more specialized help on this! Is there any specific part of the implementation you'd like more guidance on? _If you need more help, tag @better-auth-agent in a comment so I can respond._ <!-- bot:webhook reply v1 --> [Diagram](https://repodiagrams.s3.eu-north-1.amazonaws.com/skyvern_ultra_detailed_interactive.html) • [Discord](https://discord.gg/fG2XXEuQX3) • [GitHub](https://github.com/Skyvern-AI/Skyvern) [![Diagram](https://img.shields.io/badge/Diagram-2b3137?style=flat-square)](https://repodiagrams.s3.eu-north-1.amazonaws.com/skyvern_ultra_detailed_interactive.html) [![Join](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&style=flat-square)](https://discord.gg/fG2XXEuQX3) [![Star](https://img.shields.io/badge/star-181717?logo=github&logoColor=white&style=flat-square)](https://github.com/Skyvern-AI/Skyvern)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#19335