Uploading a site with cPanel File Manager: zip upload, extract, public_html and file permissions
1. Why File Manager, and why a zip?
File Manager is the cPanel tool for managing the files in your hosting account from your browser. There's nothing to install.
Uploading hundreds of files one by one takes a long time and can leave some files missing. Instead, you turn your site into a single zip file on your computer, upload it, then extract it in cPanel with one click. The sample zip in this guide is called gyro-proje-site.zip.
Hosting plans have no SSH (command line). You handle files with File Manager or FTP (see B15).
2. public_html: which folder does your site go in?
When File Manager opens you see your account's home directory (/home/username). It contains several folders; the one that matters for your site is public_html.
| Folder | What it's for |
|---|---|
| public_html | The site for your main domain. When ornekfirma.com is opened, the files in this folder are served. |
| public_ftp | A folder reserved for anonymous FTP; not used for your site. |
| mail, etc, ssl, logs, tmp | Mailboxes, settings, certificates, log files. Don't change these by hand. |
Your site's home page must sit directly inside public_html as index.html or index.php. If it ends up in a subfolder such as public_html/site/index.html, your site opens at ornekfirma.com/site instead of ornekfirma.com.
Your addon domains and subdomains have their own folders, set when you add the domain (see B17 and B18).
3. Upload the zip file
- On your computer, open the folder that holds your site. Select the files inside it (not the folder itself) and compress them to a zip. That way
index.htmllands directly in the target folder when the zip is extracted. - In cPanel, open File Manager in the Files group.
- Double-click the public_html folder in the tree on the left or in the list.
- Press Upload in the toolbar at the top.
- The File Upload page opens. The top of the page shows the folder the file will be uploaded to; check it's the right one.
- Drag your zip file onto the dashed area, or press Select File and choose it.
- Wait until the progress bar reaches 100% and the upload completes.
- Use the Go Back link at the bottom of the page to return to File Manager.
If you are uploading a file with the same name again, tick Overwrite existing files; otherwise the upload is refused.
4. Extract the zip file
- Click your zip file in the list once to select it (the row turns blue).
- Press Extract in the toolbar.
- In the Extract window, check the path the files will be extracted to. The default is the folder the zip is in (for example
/public_html). - Press Extract Files.
- Close the window that lists the extraction results and press Reload.
Your site files now appear in the folder. You no longer need the zip file; select it and press Delete.
In the screenshots, the sample site was extracted into the sample account's public_html/gyro-proje folder. Extract your own site directly into public_html.
5. Check file permissions
File permissions decide who the server lets read and write each file. The Permissions column in the list shows each file's value.
| Type | Correct value | Meaning |
|---|---|---|
Files (.html, .php, .css, images) |
644 | You read and write; visitors only read. |
| Folders | 755 | You write; visitors can enter and read. |
| A settings file holding secrets (for example a database password) | 600 or 640 | Stricter, if your application supports it. |
To change a permission:
- Select the file or folder.
- Press Permissions in the toolbar.
- In the Change Permissions window, tick the Read, Write and Execute boxes under User, Group and World. The numeric value appears in the Permission boxes below (for example 6, 4, 4 = 644).
- Press Change Permissions.
Never give a file or folder 777. It means anyone can write to it, and it's the hole malware uses most often. If a plugin asks for 777, try 755 first; if the problem persists, open a support ticket.
6. Show hidden files (.htaccess)
Files whose names start with a dot (.htaccess, .user.ini and so on) are hidden from the list by default. To set up redirects or PHP settings you need to see them:
- Press Settings at the top right.
- In the Preferences window, tick Show Hidden Files (dotfiles).
- Press Save.
In the same window you can choose which folder File Manager opens in every time (for example Web Root (public_html or www)).
7. Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
| A file listing or blank page appears instead of the site | No index.html / index.php, or it stayed in a subfolder |
Move the files directly into public_html (Move). |
The site opens at ornekfirma.com/site-name |
The zip was made with the folder itself inside | Select the files in the subfolder and Move them to /public_html. |
| 403 Forbidden error | Wrong file/folder permission or an .htaccess rule |
Set files to 644 and folders to 755; see B09 for more. |
| 500 error | A bad line in .htaccess or a PHP error |
Temporarily rename .htaccess and retry; check the PHP version. |
| The upload stops halfway | The file is too large or the connection dropped | Split the site into a few smaller zips, or upload with FTP (B15). |
| File names with non-English characters look broken | The zip was made with a different character encoding | Avoid non-English characters and spaces in file names (iletisim.html, about.html). |
8. Frequently asked questions
Can I upload rar or 7z instead of zip?
File Manager's Extract tool works with zip, tar and gz archives. Zip is the most trouble-free; open a rar/7z file on your computer and re-compress it as zip.
Can I get back a file I deleted?
Files you remove with Delete in File Manager go to the Trash, unless you chose permanent deletion in the delete window. Open View Trash, select the file and press Restore. If you emptied the trash, check your backups (B20).
I'm installing WordPress. Do I need to upload a zip?
No. You can install WordPress in a few clicks with Softaculous Apps Installer in cPanel. The zip method is for uploading a ready-made site or a backup from somewhere else.
Can I edit a file in the browser?
Yes. Select the file and press Edit; it opens in the browser. We recommend making a copy first (Copy).
How do I download many files to my computer?
Select the files, use Compress to make one zip, then select the zip and press Download.
If you have a cPanel account with another provider, you don't have to move files one by one: our team migrates up to 2 sites for free (B19).
Next steps
- Uploading many or large files? B15 — Creating an FTP account and connecting with FileZilla.
- See hosting plans: Web Hosting.
Thanks for your feedback!
