How to Upload a Website With FTP is an important skill for beginners, web developers, freelancers, and website owners who need to transfer website files from a computer to a web server. FTP allows you to upload, download, rename, delete, and organize files on a remote hosting account.
FTP stands for File Transfer Protocol. It has been used for website file management for many years and is supported by many hosting providers and FTP clients.
In this beginner-friendly guide, you will learn How to Upload a Website With FTP step by step. We will cover FTP requirements, choosing an FTP client, connecting to your hosting account, finding the correct website directory, uploading files, setting permissions, testing your website, troubleshooting common FTP errors, and following important security practices.

What Is FTP?
Before learning How to Upload a Website With FTP, it is important to understand what FTP means.
FTP stands for File Transfer Protocol. It is a protocol that allows files to be transferred between a local computer and a remote server over a network.
For website management, FTP can be used to:
- Upload website files
- Download website files
- Create folders
- Rename files
- Delete files
- Move files
- Replace website files
- Back up website files
- Manage website assets
For example, if you create an HTML website on your computer, FTP can be used to transfer the files to your hosting server.
A basic website might contain:
website/
├── index.html
├── about.html
├── css/
├── js/
└── images/
After uploading these files to the correct website directory, visitors can access the website through your domain.
Understanding FTP is the foundation of How to Upload a Website With FTP.
How Does FTP Work?
FTP uses a client-server model.
The FTP client runs on your computer and connects to the FTP server provided by your hosting company.
The process looks like this:
Your Computer
↓
FTP Client
↓
Internet
↓
FTP Server
↓
Website Files
Your FTP client provides a graphical interface for managing files on the remote server.
Popular FTP clients include:
- FileZilla
- WinSCP
- Cyberduck
- Transmit
FileZilla is one of the commonly used options because it supports multiple file transfer protocols and is available for different operating systems.
FTP vs SFTP
Before learning How to Upload a Website With FTP, you should understand the difference between FTP and SFTP.
FTP and SFTP are not the same protocol.
FTP
Traditional FTP does not encrypt the connection by default. Depending on the configuration, usernames, passwords, and transferred information may be exposed.
SFTP
SFTP stands for SSH File Transfer Protocol and operates through SSH. It provides an encrypted connection.
If your hosting provider supports SFTP, it is generally a better choice for secure file transfers.
Here is a simple comparison:
| Feature | FTP | SFTP |
|---|---|---|
| Protocol | FTP | SSH File Transfer Protocol |
| Encryption | Not by default | Yes |
| Common port | 21 | 22 |
| SSH required | No | Yes |
| File transfer | Yes | Yes |
| Secure authentication | Depends on setup | Yes |
FTP can still be available on many hosting accounts, but you should use an encrypted option such as SFTP or FTPS when possible.
What You Need Before Uploading a Website With FTP
Before starting How to Upload a Website With FTP, collect your FTP connection details.
Your hosting provider will usually provide:
- FTP hostname
- FTP username
- FTP password
- FTP port
- Website document root
- FTP encryption settings
A typical FTP configuration may look like:
Host: ftp.example.com
Username: website_user
Password: ********
Port: 21
Protocol: FTP
Your hosting provider may use the domain name, a server hostname, or an IP address as the FTP host.
For example:
Host: 203.0.113.10
Port: 21
Do not guess these values. Use the FTP information provided by your hosting provider.
Step 1: Prepare Your Website Files
The first step in How to Upload a Website With FTP is preparing the website files on your computer.
For a simple HTML website, your project might look like:
my-website/
├── index.html
├── about.html
├── contact.html
├── css/
│ └── style.css
├── js/
│ └── script.js
└── images/
├── logo.png
└── banner.jpg
For a PHP website, you may have:
my-website/
├── index.php
├── config.php
├── about.php
├── css/
├── js/
├── images/
└── includes/
Before uploading, check that all required files are included.
Make sure your homepage is named correctly.
For example:
index.html
or:
index.php
depending on your website.
Preparing the files correctly is an important part of How to Upload a Website With FTP.
Step 2: Install an FTP Client
You need an FTP client to connect your computer to your hosting server.
FileZilla
FileZilla is a popular FTP client that supports FTP, FTPS, and SFTP.
Download the application from the official FileZilla website and install it.
WinSCP
WinSCP is another file transfer application commonly used on Windows. It supports FTP, FTPS, SFTP, and other protocols.
Choose an FTP client that you are comfortable using.
For beginners, a graphical client is usually easier than using FTP commands in a terminal.
Installing an FTP client is the second major step in How to Upload a Website With FTP.
Step 3: Connect to Your Hosting Account
Open your FTP client.
You will normally see fields for:
Host
Username
Password
Port
Protocol
Enter the details provided by your hosting company.
For example:
Host: ftp.example.com
Username: website_user
Password: your_password
Port: 21
Protocol: FTP
Then click Connect.
If your hosting provider supports encrypted FTP such as FTPS, configure the client according to the provider’s instructions.
Avoid using plain FTP over untrusted networks when a secure alternative is available.
Step 4: Understand the FTP Client Interface
After connecting, most graphical FTP clients display two main areas.
The left side represents your local computer.
The right side represents the remote server.
You may see something similar to:
LOCAL COMPUTER REMOTE SERVER
my-website/ public_html/
├── index.html ├── index.html
├── css/ ├── css/
├── js/ ├── js/
└── images/ └── images/
This makes How to Upload a Website With FTP easier to understand.
You can select files on the local side and upload them to the remote side.
Step 5: Find the Website Document Root
Before uploading your files, find the directory connected to your domain.
This directory is commonly called the document root or web root.
Depending on your hosting provider, it may be:
public_html/
or:
www/
Other environments may use:
htdocs/
httpdocs/
For VPS or dedicated servers, the directory might be something like:
/var/www/html/
The correct directory depends on your server configuration.
If you upload your website files into the wrong directory, your domain may continue showing a default hosting page or a directory listing.
Finding the correct document root is one of the most important steps in How to Upload a Website With FTP.
Step 6: Upload Your Website Files
Now you are ready to upload the website.
Open your local website directory.
On the remote side, open the correct document root.
Select your website files and folders, then upload them.
For example:
Local Computer:
my-website/
├── index.html
├── css/
├── js/
└── images/
Upload them so the server contains:
public_html/
├── index.html
├── css/
├── js/
└── images/
Do not accidentally create:
public_html/my-website/index.html
if your domain expects the homepage directly inside public_html.
After starting the upload, watch the transfer queue.
Wait until all files have successfully transferred.
Step 7: Verify the Uploaded Files
After uploading, compare the local and remote directory structures.
Check that important files exist:
- Homepage
- CSS
- JavaScript
- Images
- Fonts
- PHP files
- Configuration files
- Upload directories
For example:
public_html/
├── index.php
├── css/
├── js/
├── images/
└── includes/
If the FTP client reports failed transfers, inspect the error messages and retry those files.
Do not assume that the upload is complete simply because the transfer window closed.
Verification is an important part of How to Upload a Website With FTP.
Step 8: Check File and Directory Permissions
File permissions control who can read, write, and execute files on a Linux server.
Incorrect permissions can cause errors such as:
403 Forbidden
Permission denied
Unable to upload file
For many Linux websites, common starting permissions are:
Files: 644
Directories: 755
However, these values are not universal.
Your hosting environment or application may require different settings.
Avoid setting everything to:
777
because excessive permissions can create security risks.
If your PHP application requires a writable upload or cache directory, configure only the necessary directories according to your application’s documentation.
How to Upload a PHP Website With FTP
If you are learning How to Upload a Website With FTP for a PHP website, remember that uploading the files does not automatically make PHP work.
Your hosting server must have a compatible PHP version installed.
For example, your application might require:
PHP 8.2
You should also verify the PHP extensions required by the application.
Common PHP extensions include:
mysqli
pdo_mysql
curl
mbstring
gd
zip
openssl
The exact requirements depend on your PHP application.
For official PHP information, visit the PHP documentation.
If your PHP website uses a database, you also need to create and configure the database separately.
[Internal link: How to Create a MySQL Database in cPanel]
[Internal link: How to Create a Database User in cPanel]
How to Upload an HTML Website With FTP
A static HTML website is usually easier to upload because it does not require PHP or a database.
For example:
website/
├── index.html
├── about.html
├── services.html
├── css/
├── js/
└── images/
Upload the contents of the website folder to the domain’s document root.
After uploading, open:
https://example.com
Your index.html file should normally be loaded automatically.
If it does not load, verify that the file is located in the correct document root.
How to Upload a Website With FTP From cPanel
Some hosting providers allow you to create FTP accounts through cPanel.
To create an FTP account, open:
cPanel → Files → FTP Accounts
Click Create FTP Account.
Depending on your hosting provider, you may be able to specify:
- Login
- Domain
- Password
- Directory
- Quota
Choose the directory carefully.
If the FTP account should only manage one website, restricting it to that website’s directory can reduce the amount of server content the account can access.
After creating the account, use those credentials in your FTP client.
This is another important part of How to Upload a Website With FTP for cPanel users.
How to Create an FTP Account in cPanel
If you do not already have an FTP account, you can create one through cPanel.
Navigate to:
Files → FTP Accounts
Enter the desired login name.
Create a strong password or use the password generator provided by your hosting environment.
Then select the appropriate directory.
For example:
/public_html/client-website
This means the FTP account can be limited to the specified directory, depending on the hosting configuration.
After creating the account, cPanel may display the connection information required by your FTP client.
FTP Connection Errors and Solutions
When learning How to Upload a Website With FTP, connection problems are common.
Here are some common errors and solutions.
530 Login Authentication Failed
This usually means that the FTP username or password is incorrect.
Check your credentials.
Make sure you are using the FTP account username rather than your website administrator username.
Connection Timed Out
A timeout may happen because:
- The FTP server is unavailable
- The port is blocked
- A firewall is interfering
- The hostname is incorrect
- Passive FTP settings are required
Check your hosting provider’s FTP configuration.
Connection Refused
A connection-refused message may indicate that FTP is disabled or that you are connecting to the wrong port.
Confirm the port with your hosting provider.
If FTP is disabled, use SFTP or another supported transfer method.
Permission Denied
This usually means your FTP account does not have permission to access the directory.
Check the FTP account’s assigned directory and permissions.
Files Upload but Website Does Not Work
If the upload completes but the website does not work, check:
- Document root
- DNS settings
- File permissions
- PHP version
- Database connection
.htaccess- Server error logs
The problem may not be related to FTP itself.
How to Fix Missing Images After FTP Upload
A common problem after learning How to Upload a Website With FTP is missing images.
For example, your HTML might contain:
<img src="images/logo.png" alt="Website Logo">
The server should contain:
images/
└── logo.png
If the image is missing, check:
- File name
- Directory name
- Uppercase and lowercase characters
- Relative path
- FTP transfer status
Linux servers are usually case-sensitive.
For example:
Logo.png
and:
logo.png
may be treated as different files.
How to Fix Missing CSS and JavaScript
If the website loads without styling, inspect your browser’s developer tools.
You may see errors such as:
404 Not Found
for CSS or JavaScript files.
Check whether the files were uploaded to the correct directories.
For example:
public_html/
├── index.html
└── css/
└── style.css
Your HTML should reference the correct path:
<link rel="stylesheet" href="css/style.css">
A small path mistake can prevent your stylesheet from loading.
How to Upload a Website With FTP Securely
Security is extremely important when learning How to Upload a Website With FTP.
Traditional FTP does not encrypt the connection by default.
If your hosting provider supports SFTP or FTPS, consider using one of those secure alternatives instead.
SFTP uses SSH encryption, while FTPS uses TLS encryption.
You should also follow these security practices:
Use Strong FTP Passwords
Never use easy passwords such as:
123456
password
admin123
website123
Use a long, unique password.
Limit FTP Account Access
If possible, restrict an FTP account to the directory it actually needs.
Avoid Sharing Credentials
Do not share FTP credentials through public messages, social media, or unsecured documents.
Delete Unused FTP Accounts
Remove accounts that are no longer required.
Use Secure Transfer Options
If available, use SFTP or FTPS instead of unencrypted FTP.
Keep Your FTP Client Updated
Install updates from the official software provider.
FTP vs SFTP vs FTPS
Understanding the differences is useful when deciding how to upload a website.
| Feature | FTP | SFTP | FTPS |
|---|---|---|---|
| Encryption by default | No | Yes | TLS |
| SSH required | No | Yes | No |
| Common port | 21 | 22 | 21 or configured |
| Secure transfer | No by default | Yes | Yes |
| Common use | Legacy hosting | Server administration | Secure FTP environments |
For new deployments, choose the secure protocol supported by your hosting provider.
If you specifically need FTP, make sure you understand the security implications.
How to Upload a Website With FTP During Website Migration
FTP can also be used when moving a website from one server to another.
A typical process is:
Old Server
↓
Download Website Files
↓
Local Computer
↓
Connect to New Server
↓
Upload Website Files
↓
Configure Database
↓
Test Website
↓
Update DNS
Remember that FTP transfers files only.
If your website uses MySQL or MariaDB, you also need to export and import the database.
[Internal link: How to Migrate a PHP Website to a New Server]
How to Upload a Website With FTP Without Downtime
For a new website, downtime may not be an issue.
For an existing production website, however, you should plan the migration carefully.
A useful approach is:
- Prepare the new server.
- Upload the website files.
- Configure the database.
- Test the website.
- Perform a final synchronization.
- Update DNS.
- Monitor the new server.
- Keep the old server temporarily available.
This allows you to test most of the migration before visitors are sent to the new server.
SEO Checks After Uploading a Website
Uploading a website with FTP can affect SEO if files, URLs, redirects, or configuration are changed incorrectly.
After completing How to Upload a Website With FTP, check:
- Homepage
- Internal URLs
- 301 redirects
- Canonical URLs
- Robots.txt
- XML sitemap
- HTTPS
- Images
- Page speed
- Internal links
- Broken links
Use a crawler or browser-based testing tools to identify broken URLs.
If your website has been moved to a new domain or URL structure, configure appropriate redirects.
Common FTP Mistakes Beginners Should Avoid
When learning How to Upload a Website With FTP, avoid these common mistakes.
Uploading to the Wrong Directory
Your website may appear to be uploaded successfully but still not load because the files are not inside the document root.
Forgetting Hidden Files
Files such as .htaccess may not always be immediately visible depending on your FTP client settings.
Uploading the Parent Folder
Avoid accidentally creating:
public_html/my-website/index.html
when your domain expects:
public_html/index.html
Using 777 Permissions
Do not give unnecessary write permissions to every file and directory.
Deleting the Old Website Too Quickly
If you are migrating a live website, keep the original server until the new environment is confirmed to work.
Uploading Sensitive Files
Do not leave database backups, configuration exports, or private credentials in publicly accessible directories.
Website Upload Checklist
Use this checklist when following How to Upload a Website With FTP:
- Prepare website files
- Obtain FTP credentials
- Confirm FTP hostname
- Confirm FTP port
- Install an FTP client
- Configure the FTP connection
- Connect to the server
- Find the document root
- Upload website files
- Verify transferred files
- Check hidden files
- Check file permissions
- Configure PHP if required
- Configure the database if required
- Test the homepage
- Test CSS and JavaScript
- Test images
- Test forms
- Check HTTPS
- Check server error logs
- Remove unnecessary files
- Remove unused FTP accounts
Frequently Asked Questions
Is FTP free to use?
FTP is a network protocol, and many hosting providers include FTP access with their hosting plans. You still need a hosting account or server that provides FTP access.
What port does FTP use?
Traditional FTP commonly uses port 21 for its control connection. Additional ports may be involved for data transfers depending on the FTP mode and server configuration.
Can I upload a PHP website with FTP?
Yes. FTP can transfer PHP files to your server. However, the server must have a compatible PHP environment and any required database configuration.
Where should I upload my website?
Upload the website files to your domain’s document root. On many cPanel hosting accounts this is public_html, but your hosting provider may use another directory.
Is FTP secure?
Traditional FTP does not encrypt credentials and data by default. If your hosting provider supports it, use SFTP or FTPS for encrypted transfers.
Why does my website show a default hosting page?
Your files may have been uploaded to the wrong directory. Check your domain’s document root and make sure index.html or index.php is located there.
Why are my images not loading?
Check the image path, filename, capitalization, and whether the image was successfully uploaded.
Why am I getting a 403 error?
A 403 error can be caused by incorrect file permissions, directory restrictions, missing index files, or server configuration.
Why am I getting a 500 error?
A 500 error can be caused by PHP errors, .htaccess problems, incompatible PHP versions, incorrect permissions, or server configuration issues.
Useful External Resources
For FTP specifications and related standards, the Internet Engineering Task Force (IETF) provides authoritative technical resources.
For PHP websites, the official PHP documentation provides information about PHP configuration and server requirements.
For FTP client software, visit the official FileZilla website.
For secure file transfer using SSH, the OpenSSH official documentation is useful when considering SFTP as an alternative to traditional FTP.
Conclusion
Learning How to Upload a Website With FTP is a useful skill for beginners who want to manage website files on a hosting server.
The process is straightforward: prepare your website files, install an FTP client, collect your FTP credentials, connect to the server, find the correct document root, upload the files, verify permissions, and test the website.
If you are uploading a PHP website, remember that FTP only transfers files. You may also need to configure PHP, create a database, create a database user, and update your application’s configuration.
Security should also be a priority. Traditional FTP does not encrypt traffic by default, so use SFTP or FTPS whenever your hosting environment supports it.
Once you understand How to Upload a Website With FTP, you can upload new websites, update existing websites, transfer files during migrations, and manage your hosting environment more confidently.






Comments