
The Server Action That Ran Twice, but Only on localhost
Why a Next.js Server Action called from useEffect runs twice in development: React Strict Mode mounts every component twice. What that reveals, and where the call belongs.
Tag archive

Why a Next.js Server Action called from useEffect runs twice in development: React Strict Mode mounts every component twice. What that reveals, and where the call belongs.
Every exported Server Action is a public POST endpoint. Here's what Next.js protects for you, what it doesn't, and the ten checks I put on every action: auth, ownership, validation, cookies, rate limits and more.
Server Action runs, database updates, UI stays stale? `revalidatePath` silently no-ops in 6 production situations.
AI's top startups are barely publishing their research: The Definitive Enterprise...
More Tailscale tricks for your jailbroken Kindle: The Definitive Enterprise Guide ...
Substack writers, you need a website: The Definitive Enterprise Guide Executive...
Our position on open-weights models: The Definitive Enterprise Guide Executive...

Server Actions let you run server-side code directly from React components — no separate API route...

Kimi-K3 on HuggingFace: The Definitive Enterprise Guide Executive...
Learn how to send emails in Next.js 16 using Resend. Build contact forms, use Server Actions, create React Email templates, verify domains, and deploy to Vercel with step-by-step examples.
Understand the differences between Server Actions and API Routes in Next.js 15. Learn when to use each approach with real-world examples and performance comparisons.
Complete guide to Next.js Server Actions with Supabase. Learn validation, error handling, optimistic updates, and production patterns for type-safe forms.