Your First Deployment
Deploy a project from a source archive or repository and verify the release in the dashboard.
Your First Deployment#
This guide covers the dashboard path from local code to a recorded NexHost release. Select the service type before source configuration so the platform applies the right runtime model.
1. Prepare the project#
Keep generated dependency folders and local secrets out of a source archive. For a static project, either upload source with a build command or an output folder that contains index.html. For a server-rendered application, upload the project source and use a Frontend App rather than trying to serve .next or another server build as static files.
zip -r my-app.zip . -x "node_modules/*" ".git/*" ".env*"2. Create the service#
- Open Dashboard → New Project.
- Select the service type that matches the application.
- Choose the source method offered by that service.
- Select a stack when it matches your framework, then review the proposed commands.
For a Next.js application that uses server rendering, choose Frontend App, use the normal build command, and set the start command to the application’s production start command.
3. Configure runtime services#
Runtime services need a process that binds to the PORT environment variable and accepts connections on the container interface. For Node applications, the usual shape is:
const port = Number(process.env.PORT);
server.listen(port, "0.0.0.0");Set the health path to an endpoint that can return a successful response after the application is ready. A frontend can normally use /; an API may expose a small /health endpoint instead.
4. Deploy and verify#
Start the deployment from the review screen. The deployment detail page shows source preparation, dependencies, build, and release status. When the release succeeds, open the generated hostname displayed for the service and confirm the health endpoint or application page loads.
If the deployment stops at health checks, confirm all of the following:
- the selected service is Frontend App or Web Service, not Static Site;
- the start command starts a persistent process;
- the process listens on
process.env.PORT(or the runtime equivalent); - the configured health path exists and returns a successful response within the selected timeout.
See Deployment Troubleshooting for a guided diagnosis.