> This page is for Developer.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.bigcommerce.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.bigcommerce.com/_mcp/server.

# CLI Installation

> Scaffold a new Catalyst project locally with the Catalyst CLI, connect it to your BigCommerce store, run the development server, and push it to your own Git repository.

The Catalyst CLI is the developer-first way to set up a project. It scaffolds a new Catalyst codebase on your machine, connects it to a BigCommerce store, and initializes a fresh Git repository for you. To create a Catalyst channel with the REST Management API instead, see [Manually create a Catalyst channel](/developer/docs/storefront/catalyst/guides/manually-create-catalyst-channel).

## Prerequisites

Make sure you've met the [prerequisites](/developer/docs/storefront/catalyst/getting-started/prerequisites) before you continue.

## Create the project

### Run the Catalyst CLI

```shell showLineNumbers={false}
pnpm create @bigcommerce/catalyst@latest
```

The CLI walks you through naming your project, authenticating with your BigCommerce store via your browser, and connecting a channel. It then installs dependencies and initializes a Git repository in your new project directory.

By default, the CLI scaffolds `@bigcommerce/catalyst-core`, which has **no Makeswift integration**. For a Makeswift-connected project, pass the `--gh-ref` flag:

```shell showLineNumbers={false}
pnpm create @bigcommerce/catalyst@latest --gh-ref @bigcommerce/catalyst-makeswift@latest
```

See [Makeswift](/developer/docs/storefront/catalyst/makeswift/overview) for how the two variants differ.

### Run the development server

From your new project directory, start the development server:

```shell showLineNumbers={false}
cd <your-project>
pnpm run dev
```

The following table lists localhost URLs with the default ports. When a port is unavailable, Catalyst uses the next available port. For example, if `3000` is in use, Catalyst runs on `3001`.

| Process             | URL with port           |
| :------------------ | :---------------------- |
| Catalyst storefront | `http://localhost:3000` |

## Project structure

The CLI copies only the [Catalyst storefront application](https://github.com/bigcommerce/catalyst/tree/canary/core) (the `core` directory of the Catalyst repository) into your project directory. Your project is a standalone Next.js application, not a copy of the full Catalyst monorepo.

## Push to a remote repository

Your CLI-scaffolded project already has a Git repository initialized locally, so you only need to connect it to a remote. These steps use GitHub, but any Git provider works.

1. [Create a new repository on GitHub](https://github.com/new). Don't initialize it with a README, license, or `.gitignore`, since your project already has a commit history.
2. From your project directory, add the repository as a remote and push:

   ```shell showLineNumbers={false}
   git remote add origin git@github.com:<YOUR_GITHUB_USERNAME>/<YOUR_REPOSITORY_NAME>.git
   git push -u origin HEAD
   ```

   `HEAD` pushes whichever branch you're on, so this works whether Git named your initial branch `main` or `master`.

## Next steps

* Explore the [Development](/developer/docs/storefront/catalyst/development/optimization) docs to customize caching, routing, sessions, and more.
* When you're ready to publish your storefront, see [Deploying a Catalyst storefront](/developer/docs/storefront/catalyst/deployment/overview).