---
title: "Walkthrough: Using the Getting Started template"
slug: "walkthrough--using-the-getting-started-template"
abstract: "How to use the Getting Started template to quickly set up Sitecore containers and a rendering host for your first Sitecore Headless Development experience."
---
# Walkthrough: Using the Getting Started template

> [!important]
> If you integrated your app before , it's using the legacy ASP.NET Core Rendering SDK, version 22 or earlier. This SDK is no longer receiving updates, so we recommend that you [upgrade to the latest version of the new](https://doc.sitecore.com/xmc/en/developers/asp-net/latest/asp-net-core-sdk/upgrade-from-v22.html) .

Sitecore provides a *Getting Started* template for Sitecore developers that want to try out [Sitecore Headless Development](https://doc.sitecore.com/xp/en/developers/hd/21/sitecore-headless-development/headless-development-with-the-asp-net-rendering-sdk.html "Headless development with the ASP.NET Rendering SDK") with [ASP.NET](https://dotnet.microsoft.com/apps/aspnet) and [Sitecore containers](https://containers.doc.sitecore.com/). You can use it to get started quickly or to kick-start new customer projects.

The template doesn't implement Sitecore Helix conventions for solution architecture. As you begin building your Sitecore solution, we recommend reviewing [Sitecore Helix](https://helix.sitecore.net/) and the [Sitecore Helix Examples](https://sitecore.github.io/Helix.Examples/) for guidance on implementing a modular solution architecture.

The template includes:

- A [Docker](https://www.docker.com/) environment with a Sitecore topology (by default XP0). The template also includes configuration for the XM1 and XP1 topologies.

    > [!note]
    > The template includes `docker-compose` files for every supported topology. You can find them in the `run\sitecore-<topology>` folder. For example, `run\sitecore-xm1\docker-compose.yml`. The included `docker-compose.yml` file is a standard environment from the Sitecore Container Support Package. The `docker-compose.override.yml` file for each topology contains customizations made for this solution.

- An ASP.NET rendering host.
- Serialized items for a one-page sample site. See the `src\Items.module.config` file for details.
- An [MSBuild](https://docs.microsoft.com/en-us/visualstudio/msbuild/msbuild) project named `Platform` for deploying configuration and code into the Sitecore Content Management role. See the `src\platform` folder for details.
- An MSBuild project named `RenderingHost` for an ASP.NET rendering host. See the `src\rendering` folder for details.

Before you can create a solution from the *Getting Started* template, you must install some software components and install the template.

This walkthrough describes how to:

- Install the prerequisites
- Install the template
- Create the MyProject solution
- Test the MyProject solution
- Deploy the application

## Install the prerequisites

Before you can install the template and create a solution, install the following software components on your workstation:

- [.NET Core 6.0 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/6.0) (check your installed version with the `dotnet --version` command)
- [.NET Framework 4.8 SDK](https://dotnet.microsoft.com/download/dotnet-framework/net48) (see the [Microsoft procedure for checking .NET Framework versions](https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/how-to-determine-which-versions-are-installed))
- [Visual Studio 2022](https://visualstudio.microsoft.com/downloads/)
- [Docker for Windows](https://docs.docker.com/docker-for-windows/install/) (with Windows Containers and Compose V2 enabled)
- [PowerShell 5.1](https://docs.microsoft.com/en-us/skypeforbusiness/set-up-your-computer-for-windows-powershell/download-and-install-windows-powershell-5-1) (Check your installed version with the `$PSVersionTable.PSVersion` command. PowerShell 7 is not supported.)

See the [Sitecore Containers](https://doc.sitecore.com/xp/en/developers/103/developer-tools/en/containers-in-sitecore-development.html) documentation for more information on system requirements.

## Install the template

You download and install the template in your file system. Afterward, you can create solutions based on the template.

To install the template:

1. Open PowerShell with administrator privileges.
2. Run the following command:

    ```text
    dotnet new --install Sitecore.DevEx.Templates --nuget-source https://nuget.sitecore.com/resources/v3/index.json
    ```

The `dotnet` tool does not provide obvious feedback that the installation was successful. However, the install command ends by listing all of the installed templates. If the install is successful, the list includes `sitecore.aspnet.gettingstarted`.

## Create the MyProject solution

You can name your solution anything you like but, in this example, we name the solution `MyProject`.

To create the `MyProject` solution:

1. Open PowerShell with administrator privileges.
2. Check if you have Internet Information Server running on port 443:

    ```text
    Get-Process -Id (Get-NetTCPConnection -LocalPort 443).OwningProcess
    ```

    - If you do, you must stop it:

        ```text
        iisreset /stop
        ```

3. Check if you have Apache Solr or any other service running on port 8984:

    ```text
    Get-Process -Id (Get-NetTCPConnection -LocalPort 8984).OwningProcess
    ```

    - If you do, you must stop it:

        ```text
        Stop-Service -Name "<NAME_OF_YOUR_SERVICE>"
        ```

    - Or, if you have started it with Non-Sucking Service Manager, stop it with this command:

        ```text
        nssm stop "<NAME_OF_YOUR_SERVICE>"
        ```

4. Go to your solutions folder and create the `MyProject` solution and project:

    ```text
    dotnet new sitecore.aspnet.gettingstarted -n MyProject
    ```

    > [!important]
    > You must use Latin characters in the project/folder name. Using non-Latin characters can give unexpected results because of character limitations in Docker registry names and URLs.

5. Go to the `MyProject/` folder.
6. Run the following script to prepare the Sitecore container environment:

    ```text
    .\init.ps1 -InitEnv -LicenseXmlPath "<PATH_TO_YOUR_license.xml_FILE>" -AdminPassword "<YOUR_DESIRED_SITECORE_PASSWORD>" -Topology <topology>
    ```

    Provide an absolute path for the license file. Example: `C:\license.xml`

    You'll use the password you specify here in a next step to log in to the Sitecore Identity Server.

    The `-Topology` parameter is optional. Supported values for the `-Topology` parameter are `xp0` (default), `xm1`, and `xp1`.

    The script prepares the following items:

    - A valid/trusted wildcard certificate for `*.myproject.localhost`.
    - The hosts file entries for `myproject.localhost`.
    - The required environment variable values in the `.env` file for the Sitecore instance.
7. Download the Sitecore Docker images and install the containers:

    ```text
    .\up.ps1
    ```

    The template creates the following entries in the Windows `hosts` file. Each of them points to a Sitecore container:

    - [`https://id.myproject.localhost/`](https://id.myproject.localhost/) points to the `myproject_id_1` container with a Sitecore instance hosting [Sitecore Identity Server](https://doc.sitecore.com/xp/en/developers/103/platform-administration-and-architecture/en/sitecore-identity-server.html).
    - [`https://cm.myproject.localhost/`](https://cm.myproject.localhost/) points to the `myproject_cm_1` container with a Sitecore instance hosting [Content Management](https://doc.sitecore.com/xp/en/developers/103/platform-administration-and-architecture/en/content-management--cm-.html), [Content Delivery](https://doc.sitecore.com/xp/en/developers/103/platform-administration-and-architecture/en/content-delivery--cd-.html), and [Sitecore Layout Service](https://doc.sitecore.com/xp/en/developers/hd/21/sitecore-headless-development/sitecore-layout-service.html "Sitecore Layout Service").
    - [`https://www.myproject.localhost/`](https://www.myproject.localhost/) points to the `myproject_rendering_1` container with the [rendering host](https://doc.sitecore.com/xp/en/developers/hd/21/sitecore-headless-development/headless-development-with-the-asp-net-rendering-sdk.html "Headless development with the ASP.NET Rendering SDK").
8. Wait for the script to open a browser tab for the [Sitecore Identity Server](https://doc.sitecore.com/xp/en/developers/103/platform-administration-and-architecture/en/sitecore-identity-server.html). Then log in and accept the device authorization.
9. Wait for the script to open browser tabs for Content Management and the rendering host.

The application does not include a reference to the `.env` file in the `.gitignore` file so that developers can share initialized environment variables. If you check your `.env` file into source control, other developers can prepare a certificate and `hosts` file entries by simply running the `init.ps1` script.

If your Sitecore solution or its data are sensitive, we recommend excluding the `.env` file from source control and providing other means of centrally configuring the variables.

## Test the MyProject solution

After creating your solution, you can modify and publish it using the Content Editor and use Visual Studio to modify and publish your code.

To test the solution:

- Follow the instructions to [publish, run, and test the Getting Started template](https://doc.sitecore.com/xp/en/developers/hd/21/sitecore-headless-development/publish,-run,-and-test-the-getting-started-template-projects.html "Publish, run, and test the Getting Started template projects").

> [!tip]
> Review the `README` files in the projects and the solution for additional information.

## Deploy the application

You deploy a Sitecore ASP.NET application like any other ASP.NET application.

To deploy the application:

- Follow the steps in the [official Microsoft documentation](https://learn.microsoft.com/en-us/aspnet/core/host-and-deploy/?view=aspnetcore-6.0).