2021-10-11 12:57:54 +00:00
# Commands
Nuxi is the new CLI experience for Nuxt 3
2021-10-11 16:37:38 +00:00
Nuxt 3 has two main commands, one to start development server and one to make production assets.
2021-10-11 12:57:54 +00:00
2021-10-11 16:37:38 +00:00
Since Nuxt 3 becomes a dev dependency thanks to the new [Nitro server ](/concepts/server-engine ), you only need to add two commands in your `package.json` :
2021-10-11 12:57:54 +00:00
2021-10-29 11:26:01 +00:00
```json [package.json]
2021-10-11 12:57:54 +00:00
"scripts": {
"dev": "nuxi dev",
"build": "nuxi build",
}
```
2021-10-11 16:37:38 +00:00
Then, you can run each command using `npm run <command>` or `yarn <command>` .
2021-10-11 12:57:54 +00:00
## Development Server
2021-10-29 11:26:01 +00:00
To start Nuxt in development mode with hot module replacement on < http: / / localhost:3000 > :
2021-10-11 12:57:54 +00:00
::code-group
2021-10-29 11:26:01 +00:00
```bash [Yarn]
2021-10-11 12:57:54 +00:00
yarn dev
```
2021-10-29 11:26:01 +00:00
```bash [NPM]
2021-10-11 12:57:54 +00:00
npm run dev
```
2021-10-29 11:26:01 +00:00
2021-10-11 12:57:54 +00:00
::
## Building for production
To build your Nuxt application for production, run:
::code-group
2021-10-29 11:26:01 +00:00
```bash [Yarn]
2021-10-11 12:57:54 +00:00
yarn build
```
2021-10-29 11:26:01 +00:00
```bash [NPM]
2021-10-11 12:57:54 +00:00
npm run build
```
2021-10-29 11:26:01 +00:00
2021-10-11 12:57:54 +00:00
::
2021-10-11 16:37:38 +00:00
Nuxt will create a [`.output` ](/docs/directory-structure/output ) directory with all your application, server and dependencies ready to be deployed. Checkout the [deployment ](/docs/deployment ) section to learn where and how you can deploy a Nuxt application using Nitro.
2021-10-26 17:36:22 +00:00
## Upgrade Nuxt3 version
To upgrade Nuxt3 version:
```bash
npx nuxi upgrade
```