Skip to main content
Version: 3.x

Manual Installation on Windows

The following instructions assume a 64-bit installation of Windows 10.

Prerequisites​

Before you are ready to run Saleor, you will need additional software installed on your computer.

Python​

Saleor requires Python 3.8 or later. Go to the Python download page for your operating system's installer and installation guide. You can also use pyenv to install and manage Python versions.

Make sure β€œAdd Python 3.8 to PATH” is selected.

Node.js​

Saleor requires Node.js 10.0 or later. Go to the Node.js downloads page for the installer. We recommend using the .msi format.

PostgreSQL​

You will need PostgreSQL version 12.x. Get the Windows installer from the project’s download page.

note

Remember the password you chose for the administrator account during the installation process.

GTK+​

Download and install the 64-bit Windows installer.

Make sure that β€œSet up PATH environment variable to include GTK+” is selected.

Compilers​

Download and install the latest version of the Build Tools for Visual Studio.

Installation​

Once you have installed or updated the pre-requisite software, you are ready to install Saleor. Follow the steps below to start and execute the process:

note

All commands need to be performed in either a PowerShell terminal or a Windows Command Prompt.

Installing Saleor​

  1. Clone the repository:

    git clone https://github.com/saleor/saleor.git
    cd saleor
  2. Install the dependencies into a new Python virtual environment:

python -m venv saleor-venv
saleor-venv\Scripts\activate.bat
python -m pip install -r requirements.txt
  1. Create a database user using the command line tools that came with your PostgreSQL installation:

    C:\"Program Files"\PostgreSQL\12\bin\createuser.exe --username=postgres --superuser --pwprompt saleor

    Please correct the path if your installation path or PostgreSQL version are different.

    When asked to choose a password for the new role, use "saleor" (or see how to configure Saleor to use a different password). When asked for your password, give the one you set during the installation of PostgreSQL.

    caution

    If you've decided to substitute your own credentials, make sure you create a "superuser". Otherwise, the user won't be able to install all the necessary database extensions.

  2. Create a database:

    C:\"Program Files"\PostgreSQL\12\bin\createdb.exe --username=postgres --owner=saleor saleor
  3. Migrate the database:

    python manage.py migrate
    caution

    This command creates database extensions. If you get an error related to the CREATE EXTENSION command, please return to the user creation step above.

  4. Create a super user account for dashboard

    python manage.py createsuperuser

Starting the API server​

Remember to activate your Python virtual environment if needed (you will need to do this every time you open a new terminal window):

cd saleor
saleor-venv\Scripts\activate.bat

Then execute:

python manage.py runserver

Installing the dashboard​

  1. Clone the repository:

    git clone https://github.com/saleor/saleor-dashboard.git
    cd saleor-dashboard
  2. Install the dependencies:

    npm install

Running the dashboard​

Set the API_URI environment variable to your local API server's URL:

set API_URI "http://localhost:8000/graphql/"

From within the saleor-dashboard directory, run the following command:

npm start

Your local dashboard should be accessible by visiting http://localhost:9000/.

Installing the storefront example​

  1. Clone the repository:

    git clone https://github.com/saleor/storefront.git
    cd storefront
  2. Install the dependencies:

    pnpm install

Running the storefront​

From within the storefront directory, run the following command:

pnpm dev

Your local storefront should be accessible by visiting http://localhost:3000/.


Was this page helpful?