Better Auth Security Best Practices
Configure rate limiting, manage auth secrets, set up CSRF protection, define trusted origins, secure sessions and cookies, encrypt OAuth tokens, track IP addresses, and implement audit logging for Better Auth. Use when users need to secure their auth setup, prevent brute force attacks, or harden a Better Auth deployment.
- Type
- Skill
- Author
- better-auth
- Category
- Security
- GitHub stars
- 226
- Installs
- 48.3K
- Last updated
- October 19, 2026
Install
npx skills add https://github.com/better-auth/skills --skill better-auth-security-best-practicesUse cases
- Add rate limiting to login and signup endpoints to slow brute force attempts.
- Define trusted origins and enable CSRF protection before going to production.
- Encrypt stored OAuth tokens and turn on audit logging for auth events.
Frequently Asked Questions
What does this skill cover for Better Auth security?
It covers rate limiting, auth secret management, CSRF protection, trusted origins, session and cookie hardening, OAuth token encryption, IP tracking, and audit logging.
Can it help prevent brute force attacks?
Yes, configuring rate limiting is one of the areas it walks through, alongside session and cookie hardening.
Does it apply to an existing Better Auth setup?
Yes, it is meant to tighten an existing deployment as well as secure a new one.
About this skill
Hardens a Better Auth deployment by configuring rate limiting, managing auth secrets, setting up CSRF protection, defining trusted origins, and securing sessions and cookies. It also covers encrypting OAuth tokens, tracking IP addresses, and implementing audit logging. Use it to prevent brute force attacks and tighten an existing auth setup.
Summary written with AI assistance from the project's public description.
Categories
More from better-auth
Better Auth Best Practices
Complete Better Auth server and client setup with database adapters, session management, plugins, and security configuration.
by better-auth
Email And Password Best Practices
Email verification, password reset flows, and customizable password policies for Better Auth.
by better-auth
Organization Best Practices
Multi-tenant organization setup with member management, role-based access control, and team support via Better Auth.
by better-auth
Two Factor Authentication Best Practices
Multi-factor authentication with TOTP, OTP, backup codes, and trusted device management for Better Auth.
by better-auth
Similar Skills
Find Skills
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", o...
by vercel-labs
Grill Me
A relentless interview to sharpen a plan or design.
by mattpocock
Ai Video Generation
Generate AI videos with Google Veo, Seedance 2.0, HappyHorse, Wan, Grok and 40+ models via inference.sh CLI. Models: Veo 3.1, Veo 3, Seedance 2.0,...
by inference-sh
Ai Image Generation
Generate AI images with GPT-Image-2, FLUX, Gemini, Grok, Seedream, Reve and 50+ models via inference.sh CLI. Models: GPT-Image-2, FLUX Dev LoRA, FL...
by inference-sh