PHP-fts: Building a Full-Text Search Engine in Pure PHP
Discover PHP-fts, a novel full-text search engine built entirely in PHP, eliminating external dependencies.

You’ve spent weeks building out your MVP, the core features are polished, and now it’s time to tackle authentication. This seemingly straightforward hurdle quickly becomes a decision point that can ripple through your entire tech stack and development velocity. For many, the choice narrows to established players like Supabase Auth and newer, specialized solutions like Clerk. But which one actually fits your project’s trajectory?
The fundamental challenge in modern authentication lies in striking the right balance between developer experience, feature richness, scalability, and maintaining control over your user data and identity. Do you go for an integrated solution that bundles auth with your database and backend, or opt for a dedicated auth-as-a-service that excels in its niche?
Supabase Auth positions itself as a comprehensive backend-as-a-service, deeply integrated with its PostgreSQL offering.
supabase.auth.signUp(), supabase.auth.getUser()). Session management is JWT-based, with refresh tokens offering configurable lifetimes on paid tiers. Be aware of default rate limits (e.g., 2 emails/hour) that might require custom SMTP for production.// Sign up a new user
const { data, error } = await supabase.auth.signUp({
email: '[email protected]',
password: 'example-password',
});
// Get the current user
const { data: user } = await supabase.auth.getUser();
Clerk is a specialized, developer-focused user management platform.
<SignIn />, <UserButton />) and a polished hosted dashboard, offering an exceptional developer experience. It supports MFA (TOTP, SMS), social SSO, magic links, and organizations/multi-tenancy. It boasts SDKs primarily for the modern JavaScript ecosystem (React, Next.js, Remix, Node.js). Enterprise SSO via SAML/OpenID Connect is available. It uses a hybrid auth model and has backend API rate limits.// React component for sign-in
import { SignIn } from "@clerk/nextjs";
function Page() {
return <SignIn />;
}
Beyond Supabase and Clerk, the auth landscape is evolving. You’ll see solutions like the emergent “Better Auth” (seen with Val Town) which focus on ultra-lightweight, type-safe solutions often using secure cookie-based sessions rather than JWTs. These offer maximum control and performance but come with the overhead of self-management and a less mature ecosystem.
For startups and MVPs where speed and stack compression are king, Supabase Auth is a compelling choice, provided you are comfortable with its opinionated architecture and potential for vendor coupling.
For SaaS applications, especially those built with modern JavaScript frameworks (React, Next.js), that prioritize a rapid, polished developer experience and rich user management features, Clerk is often the superior option, provided you have carefully modeled the potential long-term cost implications and accept the trade-off of vendor lock-in.
If your project demands ultimate control, has very specific security requirements, or you foresee needing to swap auth providers frequently, you might need to explore building your own or leveraging more foundational libraries, but be prepared for the significant increase in engineering effort. Choose wisely, as your authentication solution will likely be with you for a long time.