Skip to content
AWS Infrastructure

Next.js on AWS.
Defined as code.

I run Next.js on AWS Lambda, CloudFront and DynamoDB, the stack this site runs on. Every feature stays, and the bill follows use.

See the case studies
An open server rack lit by one overhead lamp in a dark data hall

This site

Runs on SST, OpenNext, Lambda, CloudFront and DynamoDB

No lock-in

Your own AWS account, defined as code and billed per use

What I build

Reading the AWS bill

A line-by-line read of the AWS bill finds oversized resources, unused storage and wrong pricing tiers.

Next.js on AWS Lambda

Run Next.js on Lambda through OpenNext and SST v3, with no Vercel lock-in. Idle apps wake in under 200ms.

DynamoDB & data layer

Swap costly managed databases for DynamoDB, priced per request. It scales from zero traffic to millions of requests.

IAM & security hardening

Least-privilege IAM, so each service gets only the access it needs. SCP guardrails, CloudTrail audit logs and no stored credentials.

CI/CD pipeline setup

GitHub Actions deploys via OIDC, with no AWS keys stored. Pushes deploy, PRs get previews, failures roll back.

DNS, SSL & CDN

Route 53 runs your DNS and ACM renews certificates itself. CloudFront caches static and dynamic content close to every visitor.

Migration scenarios

Vercel to AWS migration

Zero-downtime cutover

A Next.js app moves off Vercel Pro onto Lambda and CloudFront. Server rendering stays, and every AWS service opens up.

Firebase to AWS migration

Auth, data and hosting

Firestore becomes DynamoDB, Firebase Auth becomes Auth.js on DynamoDB, and Firebase Hosting becomes CloudFront and S3. No more vendor lock-in.

Startup MVP infrastructure

Billed per use

Lambda, DynamoDB and SES bill per use, so an MVP grows to thousands of users without a rebuild.

AWS bill optimization

Starts with the bill

Right-sized EC2, serverless where it fits, Savings Plans and cost alerts on an existing account.

Stack I work in

AWS LambdaCloudFrontDynamoDBS3SESRoute 53ACMIAMCloudWatchSST v3OpenNextNext.js 15GitHub ActionsOIDC FederationAuth.js v5Node.js 22TypeScriptInfrastructure as CodeSingle-table designGSI design

Next.js on AWS, answered

How a Vercel or Firebase app moves to AWS.

  • Yes. Pooya Golchian moves Next.js apps from Vercel to AWS Lambda and CloudFront with SST v3 and OpenNext. SSR, ISR and API routes stay intact. The cutover has zero downtime, with DNS propagation and SSL provisioning handled in the move.

  • Pooya Golchian compiles the Next.js build into Lambda functions with OpenNext. One SST v3 config file declares Lambda, CloudFront, DynamoDB, S3, Route 53 and IAM. SSR, ISR and API routes all keep working. Cold starts stay under 200 milliseconds, and CloudFront handles edge caching.

  • Start with a line-by-line read of the AWS bill. Oversized EC2 instances, forgotten storage and wrong pricing tiers cause most waste. Pooya Golchian right-sizes compute, moves suitable workloads to Lambda and DynamoDB on-demand pricing, applies Savings Plans and sets cost alerts.