Skip to content
Docs Try Aspire

aspire stop command

aspire stop - Stop a running Aspire AppHost.

Aspire CLI
aspire stop [<resource>] [options]

The aspire stop command stops a running Aspire AppHost process, or a specific resource within a running AppHost. When a <resource> name is provided, only that resource is stopped. When no resource is specified, the entire AppHost and all its child processes are stopped.

When executed without the --project option and without a resource name, the command:

  1. Scans for all running AppHost processes.
  2. If multiple AppHosts are running within the current directory scope, prompts you to select which one to stop.
  3. If only one AppHost is running in scope, stops it directly.
  4. If no in-scope AppHosts are found but out-of-scope AppHosts exist, displays all running AppHosts for selection.

The command sends a stop signal to the CLI process that started the AppHost, which ensures a clean shutdown of all resources including the dashboard and any containers or processes that were started.

  • <resource>

    The name of the resource to stop. If not specified, stops the entire AppHost. When a resource name is provided, only that specific resource within the running AppHost is stopped.

The following options are available:

  • --project <path>

    The path to the Aspire AppHost project file. When specified, the command stops only the AppHost running from that project file without prompting for selection.

  • -?, -h, --help

    Prints help and usage documentation for the available commands and options.

  • -d, --debug

    Enable debug logging to the console, which prints detailed information about what Aspire CLI is doing when a command is run.

  • Stop the AppHost running in the current directory scope:

    Aspire CLI
    aspire stop
  • Stop a specific AppHost project:

    Aspire CLI
    aspire stop --project './src/MyApp.AppHost/MyApp.AppHost.csproj'
  • Stop a specific resource within a running AppHost:

    Aspire CLI
    aspire stop myresource