GitHub Issues
Browse open issues or report a bug.
Discord
Ask questions and discuss ideas with the community.
Development setup
1
Fork and clone the repository
Visit github.com/better-auth/better-auth
and click Fork. Then clone your fork:
2
Install dependencies
3
Set up environment variables
4
Create a feature branch
5
Start the development server
Running tests
Better Auth uses Vitest. Test files live next to the source files they cover.Using the test instance helper
runWithUser and signInWithTestUser for
authenticated test scenarios:
Code style
Better Auth uses Biome for formatting and linting.- Use tabs for indentation in TypeScript; 2 spaces in JSON.
- Avoid
anytypes and unsafe typecasts. - Prefer functions and plain objects over classes.
- Do not use runtime-specific APIs like
Bufferin library code. UseUint8Arrayinstead.
PR guidelines
-
Target the
canarybranch, notmain. -
Use Conventional Commits for commit
messages:
- Keep PRs focused on a single change.
- Add tests for new features and bug fixes.
- Update documentation when changing public APIs.
-
If a PR fixes a numbered GitHub issue, add a JSDoc
@seecomment to the relevant test:
Contribution areas
Need help?
- Open a GitHub issue
- Ask in Discord
- Reach out to the maintainers