Upload and download files
IntelliJ IDEA provides the following main ways to upload project files and folders to deployment servers:
Manually, at any time through a menu command.
Automatically, every time a file is updated, or before starting a debugging session, or during a commit to your version control system.
For downloading files and folders, IntelliJ IDEA supports only the manual mode.
IntelliJ IDEA shows the logs in the File Transfer tool window ( ).
Enable the FTP/SFTP/WebDAV Connectivity plugin
This functionality relies on the FTP/SFTP/WebDAV Connectivity plugin, which is bundled and enabled in IntelliJ IDEA by default. If the relevant features aren't available, make sure that you didn't disable the plugin.
Press Control+Alt+S to open the IDE settings and then select.
Open the Installed tab, find the FTP/SFTP/WebDAV Connectivity plugin, and select the checkbox next to the plugin name.
Upload a file or folder manually
In the Project tool window (Alt+1), right-click a file or folder, then select Deployment | Upload to from the context menu, and choose the target deployment server or server group from the list.
If the default server or server group is appointed, you can also select Upload to <default deployment server or server group>.
Upload locally changed files
Switch to the Changes view (Alt+0) to view the locally changed files.
Right-click a file, then select Deployment | Upload to from the context menu, and choose the target deployment server or server group from the list. If the default server or server group group is appointed, you can also select Upload to <default deployment server or server group>.
For more information, refer to Add files to Git and track changes.
Upload files after synchronizing with a VCS repository
Synchronize the contents of your local files with the VCS repository by pressing Command T or selectingfrom the main menu.
Switch to the Update Info tab of the Version Control tool window Alt+9.
Right-click a file, then select Deployment | Upload to from the context menu, and choose the target deployment server or server group from the list. If the default server or server group is appointed, you can also select Upload to <default deployment server or server group>.
Upload checked-in files immediately after commit
In the Changes view (Alt+0), click to open the commit setting context menu.
In the After Commit area of the menu, choose the target server or server group from the Upload files to list. Choose one of the existing configurations or create a new one: click and configure access to the relevant server, or set up a server group in the dialog that opens.
To have your selection applied automatically in the future, select the Always use selected server or group of servers checkbox.
Proceed with committing your changes.
Configure automatic upload of changed files to the default server or server group
IntelliJ IDEA considers a local file changed as soon as it is saved either automatically or manually (Save and revert changes. Changed files can be automatically uploaded only to the default deployment server.or Control+S), see
Open the Options dialog by doing one of the following:
In the Settings dialog (Control+Alt+S), go to .
From the Upload changed files automatically to the default server list, choose when you want IntelliJ IDEA to upload changed files:
To upload any manually or automatically saved file, choose Always.
To upload only manually saved files, choose On explicit save action.
To suppress automatic upload, choose Never.
If you enabled automatic upload, optionally configure the scope it should apply to:
Select Skip external changes to exclude local changes that were made using a third-party tool (a VCS, a script, and so on) from automatic upload.
Select Delete remote files when local are deleted to have IntelliJ IDEA automatically delete remote files during automatic uploads in case the local ones are deleted.
Note that this option serves as an extra safety measure and may result in unwanted files remaining on the remote server. As an example, consider a local file Foo.php, which is renamed to Bar.php. Since renaming a file is technically indistinguishable from deleting the file and creating a new one, the following will happen after automatic upload:
If the option is enabled, the remote server will only contain Bar.php.
If the option is disabled, the remote server will contain both Foo.php and Bar.php after automatic upload. You will probably need to delete Foo.php manually afterwards.
Download a file or folder
Go to Tools | Deployment | Browse Remote Host.
In the Remote Host tool window that opens, select the required file or folder and choose Download from here from the context menu of the selection.
Download a file from the default deployment server
IntelliJ IDEA will prompt you to overwrite local files, if any.