---
title: "Set up a secure FTP server on Windows with IIS and FTPS · CloudSat"
description: "Install the IIS FTP service on Windows Server or Windows 11, require TLS, isolate each user, make passive mode work through firewalls, or switch to SFTP."
url: https://cloudsat.io/learn/iis-ftps-server-windows
updated: 2026-11-18T12:00:00Z
source: CloudSat (https://cloudsat.io/). Prices in USD.
---

[Networking](https://cloudsat.io/learn/topic/networking-and-dns)

# Set up a secure FTP server on Windows with IIS and FTPS

Install the IIS FTP service on Windows Server or Windows 11, require TLS, isolate each user, make passive mode work through firewalls, or switch to SFTP.

CloudSat team November 18, 2026 6 min read

Windows has shipped an FTP server for decades as part of IIS, and it still works well on Windows Server 2025 and Windows 11. The guides written for Windows 10 usually stop at plain FTP, which sends user names, passwords and files across the network unencrypted. This one sets up FTPS (FTP over TLS) with a dedicated account, an isolated folder and a passive port range that survives firewalls. If nothing forces you to use FTP, the last section shows the simpler alternative.

## FTPS or SFTP?

|  | FTPS (IIS) | SFTP (OpenSSH) |
| --- | --- | --- |
| Protocol | FTP with TLS encryption | File transfer over SSH |
| Ports | 21 plus a passive data range | 22 only |
| Built into Windows | IIS FTP Service role | OpenSSH Server, installed by default on Windows Server 2025 |
| Accounts | Windows users and NTFS permissions | Windows users and NTFS permissions |
| Pick it when | A partner, scanner or legacy app only speaks FTP | You control both ends |

Both are encrypted. FTPS exists for compatibility; SFTP is easier to firewall. Plain, unencrypted FTP is not on the list: anyone on the path between client and server can read the password, and automated bots try common FTP user names and passwords against every server they find.

## Step 1: install the FTP service

On Windows Server, run PowerShell as Administrator:

```powershell
Install-WindowsFeature -Name Web-Ftp-Server -IncludeAllSubFeature -IncludeManagementTools
```

On Windows 11 Pro, list the IIS FTP features first so you use the exact names your build offers, then enable them with the management console:

```powershell
Get-WindowsOptionalFeature -Online | Where-Object FeatureName -like "IIS-FTP*"
Enable-WindowsOptionalFeature -Online -FeatureName IIS-FTPServer, IIS-FTPSvc, IIS-ManagementConsole -All
```

## Step 2: create an account and a folder

Give each person or system its own local account, so you can revoke one without touching the others. Use a long generated password: NIST's current guidance asks for at least 15 characters when a password is the only factor.

```powershell
$pw = Read-Host -AsSecureString "Password for ftp-upload"
New-LocalUser -Name "ftp-upload" -Password $pw -PasswordNeverExpires -Description "FTPS upload account"
New-Item -ItemType Directory -Path "C:\ftp\LocalUser\ftp-upload"
icacls "C:\ftp\LocalUser\ftp-upload" /grant "ftp-upload:(OI)(CI)M"
```

The `LocalUser\<name>` layout is what IIS user isolation expects for local accounts: each user lands in their own folder and cannot browse anyone else's.

## Step 3: get a certificate

FTPS needs a server certificate in the computer's Personal store. You have two choices:

- **A public certificate** for a name such as `files.example.com`, issued by Let's Encrypt through a Windows ACME client like win-acme. Clients trust it without warnings. The DNS record must point at the server first.
- **A self-signed certificate** for internal use. Clients will warn on first connection, and users should compare the fingerprint before accepting it.

```powershell
New-SelfSignedCertificate -DnsName "files.example.com" -CertStoreLocation "Cert:\LocalMachine\My"
```

## Step 4: create the FTP site

Open IIS Manager, right-click **Sites** and choose **Add FTP Site**:

1. **Site information:** name the site `files` and set the physical path to `C:\ftp`.
2. **Binding and SSL settings:** keep all unassigned addresses and port 21, choose **Require SSL**, and select your certificate.
3. **Authentication and authorization:** enable **Basic** authentication only, allow access to **Specified users**, enter `ftp-upload`, and tick **Read** and **Write**.

Then open the new site's **FTP User Isolation** feature and choose **User name directory (disable global virtual directories)**. Anonymous access stays off, which is what you want on anything reachable from the internet.

## Step 5: make passive mode work

FTP opens a second connection for every listing and transfer. In passive mode the client connects to a port the server announces, so the server needs a fixed range that the firewalls let through. Set it at the server level in **FTP Firewall Support**, or with `appcmd`:

```powershell
& "$env:windir\system32\inetsrv\appcmd.exe" set config -section:system.ftpServer/firewallSupport /lowDataChannelPort:50000 /highDataChannelPort:50100 /commit:apphost
Restart-Service ftpsvc
```

The site-level **External IP Address of Firewall** setting only matters when the server sits behind NAT and its adapter carries a private address. On a cloud server whose public address is on the network adapter, leave it empty.

Encryption breaks one convenience. Windows Firewall normally reads FTP commands to open data ports on the fly, but it cannot read an encrypted control channel. Microsoft's IIS documentation recommends turning that stateful FTP filter off for FTPS and allowing the traffic explicitly:

```powershell
New-NetFirewallRule -DisplayName "FTPS control" -Direction Inbound -Protocol TCP -LocalPort 21 -Action Allow
New-NetFirewallRule -DisplayName "FTPS passive data" -Direction Inbound -Protocol TCP -LocalPort 50000-50100 -Action Allow
netsh advfirewall set global StatefulFtp disable
```

Open the same port and range in any firewall in front of the server. On a CloudSat [Windows VPS](https://cloudsat.io/windows-vps-hosting), that means two rules in its [cloud firewall](https://cloudsat.io/docs/cloud-firewalls): TCP 21 and the range 50000-50100, ideally limited to the addresses that will upload.

## Step 6: connect and test

In FileZilla, choose the FTP protocol with **Require explicit FTP over TLS**. In WinSCP, choose FTP with **TLS/SSL Explicit encryption**. A quick command-line check uses the `curl.exe` that ships with Windows (type the `.exe`, because `curl` alone is an alias in Windows PowerShell):

```powershell
curl.exe --ssl-reqd -u ftp-upload --list-only ftp://files.example.com/
```

With a self-signed certificate, curl and most clients refuse the connection until the certificate is trusted on the client machine, which is the check doing its job.

Do not test with the old `ftp.exe` client. It supports neither TLS nor passive mode, so it fails against a correctly configured server.

Test from a machine outside the server's network, because a connection from the server to itself skips every external firewall. `Test-NetConnection files.example.com -Port 21` confirms the control port answers; a successful directory listing in FileZilla confirms the passive range works too. If the listing fails, FileZilla's message log shows the passive port the server announced, which tells you exactly which rule is missing.

## Harden the service

- Keep **Require SSL** on both the control and data channels. A server that merely allows TLS will accept clients that skip it.
- Turn on **FTP Logon Attempt Restrictions** to block addresses after repeated failed logins.
- Use **FTP IP Address and Domain Restrictions**, or firewall source rules, when uploads come from known addresses.
- Read the logs under `C:\inetpub\logs\LogFiles`, in the folder named after the FTP site's ID.
- Remove accounts the day a partner or project ends.

## The simpler alternative: SFTP

Windows Server 2025 installs OpenSSH by default; you only switch it on. On Windows 11 and Windows Server 2022, add it as a capability first:

```powershell
Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0
Start-Service sshd
Set-Service -Name sshd -StartupType Automatic
```

Setup creates the `OpenSSH-Server-In-TCP` firewall rule for port 22. Users sign in with the same Windows accounts, files are protected by the same NTFS permissions, and there is no passive range to manage. On Windows Server 2025, the **Remote SSH Access** switch in Server Manager does the same job as the service commands.

## FAQ

### Why does login work but the folder listing hangs?

The control connection on port 21 succeeded and the data connection did not. Check that the passive range is set in IIS, open in Windows Firewall and open in every firewall in front of the server.

### Explicit or implicit FTPS?

Use explicit. The client connects to port 21 and upgrades the session with `AUTH TLS`. Implicit FTPS on port 990 is an older variant that some clients still support but few setups need.

### How many passive ports do I need?

Each open data connection uses one port from the range while a listing or transfer runs. A hundred ports covers a small team comfortably. Widen the range if many clients transfer at the same time, and remember to widen every firewall rule with it.

### Can several users share one FTP site?

Yes. Create one Windows account and one folder under `C:\ftp\LocalUser` per user. User isolation keeps each of them inside their own folder.

**Run it on CloudSat.** Cloud VPS on AMD EPYC and NVMe from $1.98/mo in 13 regions, delivered in under 5 minutes and paid in crypto. [See plans](https://cloudsat.io/plans) or [deploy a server](https://dash.cloudsat.io/console/deploy).

## Keep reading

[All guides in Networking](https://cloudsat.io/learn/topic/networking-and-dns)

- [Active vs passive FTP: how the data connection works](https://cloudsat.io/learn/active-vs-passive-ftp-explained): Networking Active vs passive FTP: how the data connection works 6 min read
- [Manage Windows Firewall with Group Policy and PowerShell](https://cloudsat.io/learn/windows-firewall-group-policy-powershell): Security Manage Windows Firewall with Group Policy and PowerShell 6 min read
- [Check open and listening ports on Linux with ss and lsof](https://cloudsat.io/learn/list-listening-ports-linux): Networking Check open and listening ports on Linux with ss and lsof 6 min read
- [FTP vs FTPS vs SFTP: which file transfer protocol to use](https://cloudsat.io/learn/ftp-ftps-or-sftp-which-to-use): Networking FTP vs FTPS vs SFTP: which file transfer protocol to use 6 min read
