SFTP by MUJEER
Professional FTP, FTPS, and SFTP workflows for Visual Studio Code. Built by MUJEER for developers who want fast mapped-folder publishing, upload-on-save, folder sync, and a polished transfer console without leaving the editor.
Publisher: MUJEER
SFTP turns a local project folder into a controlled remote publishing workspace. Map once with sftp-config.json, then save, upload, download, or sync from the Explorer and keep your attention on code instead of file-transfer chores.
Highlights
- Upload on save with clear terminal telemetry
- Map any local folder to a remote folder
- Right-click file and folder actions in the VS Code Explorer
- Upload and download individual files from the Explorer
- Compare a local file with its remote version
- Browse mapped remote folders from VS Code
- Edit remote files in a temporary VS Code editor and upload them on save
- Upload only files changed since the last Git commit
- Test connection health before deploying
- Copy mapped remote paths from files or folders
- Delete remote files or folders with explicit confirmation
- Upload folders, download folders, and sync in either direction
- FTP, FTPS, and SFTP connection support
- Password authentication and SSH private key authentication
- Overwrite protection for newer remote or local files
- Configurable confirmations for downloads and sync operations
- Ignore rules for generated files, VCS folders, system files, and private config
- JSON-with-comments support for friendly
sftp-config.json files
- Colored
SFTP transfer terminal with progress bars and status badges
- Automatic terminal reveal during transfers and optional hide-on-success
- Multi-root friendly config discovery using the closest parent mapping
Explorer Workflow
Right-click a mapped file and open the SFTP menu:
Upload File publishes the selected local file to its mapped remote path.
Download File pulls the mapped remote file back into the selected local file.
Compare File with Remote downloads a temporary remote copy and opens a VS Code diff.
Edit Remote File opens the mapped remote copy in VS Code and uploads it back when saved.
Copy Remote Path copies the mapped remote path for use in terminals, tickets, or deployment notes.
Delete Remote File removes the mapped remote file after confirmation.
Right-click a mapped folder and open the SFTP menu:
Map to Remote creates sftp-config.json for a folder.
Edit Remote Mapping updates the configured remote_path.
Upload Folder publishes every non-ignored local file below the folder.
Download Folder pulls matching remote files into the selected folder.
Browse Remote lists remote files and folders, lets you navigate directories, and offers edit, download, copy, and delete actions for remote files.
Upload Changed Files publishes tracked and untracked Git changes below the selected folder.
Sync Local -> Remote uploads local files and can remove remote files that no longer exist locally.
Sync Remote -> Local downloads remote files and can remove local files that no longer exist remotely.
Test Connection validates credentials and remote path access.
Copy Remote Path copies the mapped remote folder path.
Delete Remote Folder removes the mapped remote folder after confirmation.
Folders with an existing sftp-config.json use that mapping automatically. If you open a parent workspace containing several projects, SFTP uses the closest mapping above the selected file or folder.
Save Flow
When upload_on_save is enabled, saving a mapped file starts an upload immediately. Ctrl+S / Cmd+S is bound to SFTP: Save and Upload Current File, so pressing save can upload the current file even when VS Code has no unsaved text changes.
The status bar shows the current transfer state. The SFTP terminal shows a branded, colored transfer feed with:
- timestamps
- status badges:
INFO, RUN, DONE, SKIP, FAIL
- Linux-style animated progress bars
- local and remote path summaries
- skipped file and warning messages
- connection diagnostics
- compact success and failure summaries
By default, save-triggered transfers reveal the terminal while work is happening and hide the panel after success.
Remote edit sessions use the same save pipeline. When a remote file is opened through Edit Remote File or Browse Remote, saving that temporary editor uploads the file back to its original remote path.
Configuration
Create sftp-config.json at the folder you want to map. The file supports comments and trailing commas.
{
"type": "sftp",
"save_before_upload": true,
"upload_on_save": true,
"sync_down_on_open": false,
"sync_skip_deletes": false,
"sync_same_age": true,
"confirm_downloads": false,
"confirm_sync": true,
"confirm_overwrite_newer": false,
"host": "example.com",
"user": "deploy",
"password": "your-password",
"port": "22",
"remote_path": "/public_html",
"ignore_regexes": [
"sftp-config(-alt\\d?)?\\.json",
"sftp-settings\\.json",
"/node_modules/",
"/vendor/",
"/dist/",
"/build/",
"/coverage/",
"\\.svn/",
"\\.hg/",
"\\.git/",
"\\.bzr",
"_darcs",
"CVS",
"\\.DS_Store",
"Thumbs\\.db",
"desktop\\.ini",
"\\.env"
],
"connect_timeout": 30
}
Config Reference
| Option |
Purpose |
type |
Connection protocol: sftp, ftp, or ftps. |
host |
Remote server hostname or IP address. |
user |
Remote username. |
password |
Password for FTP, FTPS, or SFTP password auth. |
port |
Remote port. Common defaults are 22 for SFTP and 21 for FTP/FTPS. |
remote_path |
Remote folder mapped to the local config folder. |
upload_on_save |
Upload saved files automatically when true. |
save_before_upload |
Save dirty files before manual upload commands. |
ignore_regexes |
Regex patterns skipped during upload, download, and sync. |
confirm_downloads |
Ask before folder downloads when true. |
confirm_sync |
Ask before sync operations when true. |
sync_skip_deletes |
Prevent sync commands from deleting missing files. |
confirm_overwrite_newer |
Warn before overwriting a newer local or remote file. |
ssh_key_file |
SFTP private key path, including ~/ paths. |
file_permissions |
Optional remote file permissions after upload. |
dir_permissions |
Optional remote directory permissions when directories are created. |
connect_timeout |
Connection timeout in seconds. |
keepalive |
Optional SFTP keepalive interval in seconds. |
allow_config_upload |
Allow uploading sftp-config.json; false by default for safety. |
Git-Aware Publishing
SFTP: Upload Changed Files uses Git to find files changed since HEAD, plus untracked files that are not ignored by Git. The command respects ignore_regexes and uploads only existing local files below the selected mapped folder.
This gives you a quick publish flow for small fixes without uploading a whole project tree.
VS Code Settings
| Setting |
Default |
Description |
sftp.terminal.autoReveal |
true |
Reveal the SFTP terminal when transfers start. |
sftp.terminal.hideOnSuccess |
true |
Hide the terminal after successful save-triggered transfers. |
sftp.terminal.hideDelay |
1200 |
Delay in milliseconds before hiding the terminal. |
Security Notes
- SFTP never writes passwords to the terminal or output log.
sftp-config.json is ignored by default and is not uploaded unless allow_config_upload is true.
- Prefer SSH keys for SFTP deployments when your server supports them.
- Keep project-specific mappings inside the project folder they deploy.
- Treat
sftp-config.json as a secret if it contains passwords.
Commands
SFTP: Save and Upload Current File
SFTP: Upload Current File
SFTP: Show Status
SFTP: Upload File
SFTP: Download File
SFTP: Compare File with Remote
SFTP: Edit Remote File
SFTP: Delete Remote File
SFTP: Copy Remote Path
SFTP: Upload Folder
SFTP: Download Folder
SFTP: Browse Remote
SFTP: Upload Changed Files
SFTP: Sync Local -> Remote
SFTP: Sync Remote -> Local
SFTP: Delete Remote Folder
SFTP: Test Connection
SFTP: Edit Remote Mapping
SFTP: Map to Remote
Launch Scope
This release focuses on reliable mapped-folder workflows: save upload, file and folder upload/download, remote browsing, remote edit sessions, remote diff, Git-aware changed-file publishing, one-way sync in either direction, colored transfer telemetry, overwrite protection, connection diagnostics, and config-driven project mapping.
Future commercial workflow areas include persistent transfer pools, transfer history, profile switching, SSH agent discovery UI, and richer bulk conflict resolution.
Troubleshooting
Run SFTP: Show Status from the command palette to reveal the transfer terminal and list detected mappings.
If a folder command asks you to map the folder, confirm that sftp-config.json exists at the folder root or one of its parent folders inside the workspace.
If a save does not upload, confirm that upload_on_save is true, the file is inside a mapped folder, and the file is not excluded by ignore_regexes.