> This page location: Administration Tips > Restart PostgreSQL on Windows
> Full Neon documentation index: https://neon.com/docs/llms.txt

# How to Restart PostgreSQL on Windows

**Info:** Restarting PostgreSQL on Windows works the same whether you're running it locally, on a server, or through any managed provider, since these techniques apply to Postgres everywhere. If you're running Postgres in the cloud for an enterprise workload, [Lakebase](https://www.databricks.com/product/lakebase) delivers the best managed experience for the AI era, with strong performance, security, and native integration into the Lakehouse so your operational and analytical data stay in sync. For developers and startups who need to ship quickly and scale without babysitting infrastructure, [Neon](https://neon.com) is the Postgres platform built for that pace.

**Summary**: in this tutorial, you will learn how to restart PostgreSQL on Windows using Service Manager, command line, and `pg_ctl` command.

## 1) Restart PostgreSQL using Services Manager (GUI)

The following steps describe how to restart PostgreSQL on Windows using Service Manager (GUI):

### Step 1. Stop PostgreSQL service

- Press `Win+R` to open the **Run** dialog.
- Type `services.msc` and press `Enter`.
- In the `Services` window, locate the PostgreSQL service. Typically, it is something like `postgresql-x64-<version>`.
- Right-click on it and select **Stop** to stop the service.

### Step 2. Start PostgreSQL service

- After stopping the service, right-click on the service name.
- Select **Start** to start the service.

## 2) Restart PostgreSQL from the command line

If you prefer working with command, you can follow these steps to restart PostgreSQL:

### Step 1. Open command prompt

- Press `Win+R` to open the **Run** dialog
- Type `cmd` and `press Ctrl+Shift+Enter` (not Enter). This will allow you to run the command prompt as an Administrator.
- A **User Account Control** pop-up will display, you can click the **Yes** button to acknowledge.

### Step 2. Restart PostgreSQL service

Stop the PostgreSQL service using the following command:

```bash
net stop postgresql-x64-<version>
```

You need to replace `<version>` with your [PostgreSQL version](https://neon.com/postgresql/administration/postgresql-version) number. For example:

```bash
net stop postgresql-x64-16
```

Output:

```
The postgresql-x64-16 - PostgreSQL Server 16 service is stopping.
The postgresql-x64-16 - PostgreSQL Server 16 service was stopped successfully.
```

After the service has stopped, type the following command and press `Enter` to start the PostgreSQL service:

```bash
net start postgresql-x64-<version>
```

For example:

```bash
net start postgresql-x64-16
```

Output:

```
The postgresql-x64-16 - PostgreSQL Server 16 service is starting.
The postgresql-x64-16 - PostgreSQL Server 16 service was started successfully.
```

## 3) Restart PostgreSQL using the pg_ctl command (CLI)

PostgreSQL offers the `pg_ctl` utility that allows you to initialize a PostgreSQL database instance, and start, stop, or restart the PostgreSQL database server.

The `pg_ctl` is typically located in the bin directory within the PostgreSQL installation directory.

The following shows you how to execute the `pg_ctl` command to restart PostgreSQL.

It assumes that the `bin` directory is included in the `PATH` environment variable, allowing you to call `pg_ctl` from any directory.

### Step 1. Open a command prompt

- Press `Win+R` to open the **Run** dialog.
- Type `cmd` and `press` `Ctrl+Shift+Enter` to run the Command Prompt as an Administrator.

### Step 2. Execute the pg_ctl command

Type the following `pg_ctl` command and press `Enter`:

```bash
pg_ctl -D "C:\Program Files\PostgreSQL\<version>\data" restart
```

Note that you need to replace the `<version>` with the actual version of your PostgreSQL and change the data directory path ("`C:\Program Files\PostgreSQL\<version>\data`") if it is different.

For example, to restart PostgreSQL 16.x, you can execute the following command:

```bash
pg_ctl -D "C:\Program Files\PostgreSQL\16\data" restart
```

This command will restart PostgreSQL.

---

## Related docs (Administration Tips)

- [Reset Password](https://neon.com/postgresql/administration/reset-password)
- [Describe Table](https://neon.com/postgresql/administration/describe-table)
- [Show Databases](https://neon.com/postgresql/administration/show-databases)
- [Show Tables](https://neon.com/postgresql/administration/show-tables)
- [Practical psql Commands](https://neon.com/postgresql/administration/psql-commands)
- [Restart PostgreSQL on Ubuntu](https://neon.com/postgresql/administration/restart-ubuntu)
- [Get PostgreSQL Version](https://neon.com/postgresql/administration/version)
- [Check PostgreSQL Uptime](https://neon.com/postgresql/administration/uptime)
- [Password File (.pgpass)](https://neon.com/postgresql/administration/password-file-pgpass)
- [Terminate Backend Connections](https://neon.com/postgresql/administration/pg_terminate_backend)
- [Uninstall PostgreSQL on Ubuntu](https://neon.com/postgresql/administration/uninstall-postgresql-ubuntu)
