Next.js 15 Server Actions in production
Server Actions reduce CRUD code by 30-50%. They also have edge cases. What we found shipping them at scale.
Server Actions in Next.js 15 let you call server-side functions directly from React components, without writing API routes. After shipping them in production:
What works great:
- CRUD forms — create, update, delete on a single page. 30-50% less boilerplate than API routes + fetch.
- Authentication flows — login, logout, password reset.
- Optimistic UI — useOptimistic + Server Actions feels native.
- Type safety — directly typed end-to-end without OpenAPI gymnastics.
What needs caution:
- File uploads. Server Actions accept FormData, but body limit is 1MB by default. For larger uploads, you still want a separate API route or signed S3 URLs.
- Long-running tasks. Server Actions hit serverless function timeouts. For anything >10 seconds, queue and webhook back.
- Caching. revalidatePath / revalidateTag is more nuanced than it looks. Get it wrong and stale data appears in production.
- Error handling. Throwing an error in Server Action shows generic message in prod (security feature). Need to return errors as values for proper UX.
Server Actions are great for 80% of CRUD. For the other 20% (long jobs, big uploads, external API calls), regular API routes still make more sense.