How to Set Up a Secure FTP Server on Windows
In this article
Yes, you can set up a secure FTP server on Windows using the built-in IIS (Internet Information Services) with FTP publishing and SSL/TLS encryption. This allows file transfers over a protected connection, restricting access to authorized users only. Before beginning, ensure you're using Windows Pro, Enterprise, or Education edition, as IIS is not available on Windows Home editions without workarounds.
What You'll Need
- Windows 10 or Windows 11 Pro, Enterprise, or Education edition
- Administrator access to the machine
- A static IP address or reserved DHCP address for the server
- Optional: a domain name if allowing external access
- Optional: a trusted SSL certificate (you can use a self-signed one for internal use)
Step-by-Step
- Open Control Panel > Programs > Turn Windows features on or off.
- In the list, expand Internet Information Services.
- Check the box for Internet Information Services. This installs the base components.
- Expand FTP Server and check both FTP Service and FTP Extensibility.
- Expand World Wide Web Services under Web Management Tools, and ensure Management Console is selected.
- Click OK. Windows will install the features. This may take a few minutes and might prompt a restart.
- After installation, open IIS Manager from the Start menu.
- In the Connections pane, expand your computer name and right-click on Sites > Add FTP Site.
- Enter a site name (e.g., SecureFTP), and set the physical path (e.g., C:\FTP). Create this folder if it doesn’t exist.
- Click Next. For IP address, select the server’s IP or use All Unassigned. Set port to 21.
- Under SSL, select Require SSL. You’ll need a certificate later.
- Set Authentication to Basic (required for user login). Set Authorization to allow specific users or groups, and assign Read and Write permissions as needed.
- Click Finish to create the site.
- Back in IIS Manager, click on your FTP site, then double-click FTP SSL Settings.
- Check Require SSL connections, and under SSL certificate, select a trusted certificate or use a self-signed one generated via IIS.
- To create a self-signed certificate: In IIS Manager, select your server name, open Server Certificates, and click Create Self-Signed Certificate. Name it and assign to the FTP site.
- Go to FTP Authentication and ensure only Basic Authentication is enabled.
- Under FTP Authorization Rules, remove any unnecessary access and confirm only intended users or groups have permission.
- Create Windows user accounts for FTP access: Open Settings > Accounts > Family & other users > Add account. Choose “I don’t have this person’s sign-in info” and create a local user. Set a strong password.
- Back in IIS, ensure the user has file system permissions: Right-click the FTP folder (e.g., C:\FTP), select Properties > Security > Edit > Add, enter the username, and assign Modify or Full Control as needed.
- Test the connection locally using an FTP client like FileZilla: Use ftp://localhost, port 21, with explicit TLS. Enter the username and password.
- For external access, configure your router to forward port 21 and, if using passive mode, a range of passive ports (e.g., 50000–50100). Open these ports in Windows Defender Firewall under Inbound Rules.
- In IIS, go to FTP Firewall Support and set the external IP and passive port range.
- Always disable Anonymous Authentication and avoid using the default FTP user isolation settings unless properly configured.
Common Mistakes
Enabling Anonymous Authentication exposes the server to unauthenticated access. Not binding SSL forces unencrypted transfers. Using weak passwords or default folder permissions risks data leakage. Forgetting to open passive ports in the firewall blocks client connections. Relying on Windows Home editions that lack IIS support halts setup early.
Tips
Use strong, unique passwords for FTP users. Limit access to specific IP ranges if possible. Regularly audit logs in IIS to monitor login attempts. Use a dedicated user group for FTP access to simplify management. Prefer SFTP (via SSH) over FTPS for better security, but FTPS is acceptable when properly configured.
Troubleshooting
If the FTP site won’t start, check that IIS and FTP features are fully installed. Verify the folder path exists and the user has NTFS permissions. If connections fail, ensure Windows Firewall allows FTP traffic on port 21 and passive ports. Use Test-NetConnection in PowerShell to verify port accessibility. If SSL fails, confirm the certificate is assigned and not expired. Restart the FTP site or the entire IIS service via IIS Manager if changes don’t apply. If external clients can’t connect, confirm port forwarding is set on the router and the public IP is correct.
Frequently Asked Questions
Can I use FTPS instead of regular FTP?
Yes. FTPS (FTP over SSL/TLS) is supported in IIS and is the secure method used in this guide. Always require SSL for encryption.
Is SFTP possible with this setup?
No. IIS does not support SFTP (SSH File Transfer Protocol). Use a third-party SFTP server like OpenSSH or FileZilla Server for SFTP.
Why can’t external users connect?
Check router port forwarding, firewall settings, and whether your ISP blocks port 21. Ensure passive mode ports are open and correctly configured in IIS.
Do I need a domain name?
No. You can use a public IP address. A domain name is optional but makes access easier.
Can I host multiple FTP sites?
Yes. IIS allows multiple FTP sites on different IP addresses or ports. Configure each with its own folder and SSL settings.
What if I’m on Windows Home?
IIS is not available. Use third-party software like FileZilla Server with SSL support, but ensure it's downloaded from the official site.