Next.js Discord

Discord Forum

build for nodejs server

Unanswered
American Wirehair posted this in #help-forum
Open in Discord
Avatar
American WirehairOP
just saw https://nextjs.org/docs/app/building-your-application/deploying and wanted to deploy my app for a nodejs server. I runned npm run build on my local pc and wondered, which files I need to upload now, to run it on my debian server?

7 Replies

Avatar
not-milo.tsx
It's not as simple as that. If you want to host a static build of your app you should read the docs on [static exports](https://nextjs.org/docs/app/building-your-application/deploying/static-exports). Just beware that not all Next.js features are supported if you do that.
Avatar
American WirehairOP
No, I don't want a static build. I want to use a NodeJS Server
Avatar
not-milo.tsx
A little bit of googling brings up this dev.to article: https://dev.to/kedzior_io/deploy-self-hosted-nextjs-application-with-net-api-43p8

I never tried doing this and I don't see the point of it. But you should be pretty familiar with VPSs and self-hosting Node.js servers in order to pull it off.
Avatar
American WirehairOP
understand. will check that out. what would you recommend for deploying a nextjs app?
Avatar
not-milo.tsx
[Vercel](https://vercel.com/home) ✨
It has a free plan that's pretty good honestly and it supports all the latest and greatest Next.js features since they're the ones developing the framework.
Avatar
American WirehairOP
would work too, yes