Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.
Port forwarding sends network traffic through an SSH connection. Open Port Forwarding in the sidebar to create saved rules, start and stop them, and see how many connections each one is carrying.
A running local rule with one connection, and a stopped SOCKS5 rule.
Listens on your machine and forwards to a destination reached from the SSH host
127.0.0.1:2200 → 127.0.0.1:22
Remote
Listens on the SSH host and forwards to a destination on your machine
Expose a local dev server on the remote host
Dynamic SOCKS5
Runs a SOCKS5 proxy on your machine and routes any TCP connection through the SSH host
127.0.0.1:1080
A rule always goes through a saved host (the SSH Host), using that host’s stored credentials. You don’t need an open terminal tab: YourSSH connects to the host on its own, and through its connection chain if it has one.
Go to Port Forwarding and click New rule. The New Port Forward Rule panel opens on the right.
2
Name the rule and pick a type
Enter a Label, then choose the Type: Local, Remote or Dynamic SOCKS5.
The type menu.
3
Set the addresses
Fill in Local Host and Port (the address that listens on your machine). For Local and Remote rules, also fill in Remote Host and Port for the destination. A Dynamic SOCKS5 rule needs only the local address, so the remote fields disappear.
4
Choose the SSH host
Pick the SSH Host the tunnel runs through. The field is marked optional so you can save a draft, but a rule without a host can’t start. It reports Select an SSH host first.
5
Optionally auto-start
Tick Auto-start on launch to bring the tunnel up each time YourSSH starts.
6
Save
Click Add Rule.
A local rule filled in: localhost port 2200 to port 22 on the remote side, through Demo Server.
Each rule has a button on the right: the play button starts it and the stop button stops it. Several tunnels can run at once, and each one is independent.The status dot on the left shows the state:
Dot
State
Grey
Idle
Amber
Connecting, or reconnecting (the rule also shows reconnecting…)
Green
Active
Red
Error. The message appears under the rule, for example that a port is already in use
An active rule shows a live connection count such as 1 conn.If a rule fails to start, check the message under it. Common causes are a local port already in use, no SSH host selected, or the host no longer existing.
If the SSH connection drops while a tunnel is running, the rule switches to reconnecting… and YourSSH reconnects with exponential backoff, starting at 2 seconds and doubling up to 30 seconds. Local listeners stay bound while it retries, so clients keep the same local port. Stopping the rule cancels the retry.
Click a rule, or right-click and choose Edit, to change it. The panel title is Edit Port Forward Rule and the button is Save. If the rule is running, stop and start it again to apply the change.
Right-click and choose Duplicate to copy a rule. The copy is named … (copy) and never auto-starts.
Hover a rule and click the trash icon, or right-click and choose Delete. YourSSH asks Delete rule? first, naming the label and endpoints, with Cancel selected by default. After you confirm, a running rule is stopped and removed. Deleting a host also stops the tunnels that use it.
The Web Tools plugin has a Port Tunnels tool that works with these forwarded ports, so you can open a tunnelled web service in the in-app browser. See Web Tools.
SFTP and Terminal use the same SSH connection settings.
DevOps Hub for Cloudflare tunnels and other tunnel tools.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"YourSSH","description":"YourSSH is a fast, open-source SSH, SFTP, RDP and VNC client for macOS, Windows, Linux and Android.","colors":{"primary":"#E87C08","light":"#F3A231","dark":"#C76A06"},"logo":{"light":"https://mintcdn.com/sen-f208ff9e/qEqMDfcJBQhRyoaC/logo/light.svg?fit=max\u0026auto=format\u0026n=qEqMDfcJBQhRyoaC\u0026q=85\u0026s=7bf37a0c27b7602b53d522578cdb816e","dark":"https://mintcdn.com/sen-f208ff9e/qEqMDfcJBQhRyoaC/logo/dark.svg?fit=max\u0026auto=format\u0026n=qEqMDfcJBQhRyoaC\u0026q=85\u0026s=b06507e41d95e5f3cc6fd7080c94ff57","href":"https://github.com/YoursshLabs/yourssh"},"favicon":"https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/favicon.svg?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=8f5150126820f7606a7100cba40b2434","appearance":{"default":"dark"},"navbar":{"links":[{"href":"https://github.com/YoursshLabs/yourssh/issues","label":"Issues"}],"primary":{"type":"button","label":"Download","href":"https://github.com/YoursshLabs/yourssh/releases/latest"}},"footer":{"socials":{"github":"https://github.com/YoursshLabs/yourssh"}},"icons":{"library":"lucide"},"contextual":{"options":["copy","view","chatgpt","claude","perplexity"],"display":"header"},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/YoursshLabs/yourssh"},{"anchor":"Releases","icon":"download","href":"https://github.com/YoursshLabs/yourssh/releases"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"sen-f208ff9e","hasAudioNarration":false,"actualSubdomain":"sen-f208ff9e","customDomains":[],"gitSource":{"type":"github","owner":"yoursshlabs","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":"","_id":"6af6c46e9292933daccbb7c4"},"entitlements":{},"buildId":"6af6e34886fb40a3af47152c","clientVersion":"0.0.4124","searchFilterCounts":[{"language":"default","tag":"User guide","count":23},{"language":"default","tag":"Connections","count":6},{"language":"default","tag":"Developer guide","count":5},{"language":"default","tag":"Tools","count":5},{"language":"default","tag":"Develop","count":3},{"language":"default","tag":"Get started","count":3},{"language":"default","tag":"Security","count":3},{"language":"default","tag":"Settings and sync","count":3},{"language":"default","tag":"Plugins","count":2},{"language":"default","tag":"Remote desktop","count":2}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"user-guide/port-forwarding","slug":"/user-guide/port-forwarding","pageMetadata":{"title":"Port forwarding","description":"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.","icon":"arrow-left-right","href":"/user-guide/port-forwarding"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Frame,Heading,OptimizedImage,Step,Steps,Table}=_components;if(!Frame)_missingMdxReference(`Frame`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Port forwarding sends network traffic through an SSH connection. Open `,_jsx(_components.strong,{children:`Port Forwarding`}),` in the sidebar to create saved rules, start and stop them, and see how many connections each one is carrying.`]}),`\n`,_jsx(Frame,{caption:`A running local rule with one connection, and a stopped SOCKS5 rule.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=ba459f1c0b941649dbac6ab395c7ec92`,alt:`Port Forwarding list with a running local rule and an idle dynamic SOCKS5 rule`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/09-running-connections.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=37c49b27a98616234cf3e1a604e5e376 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=54bab23e765e43c6e32f9e528f502e72 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=79ae65344698fe561543e21c57e5b695 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=14b9bbe799e101653782d051d8d12cdb 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=f55ea80e0df09b25fd011739bb64b605 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/09-running-connections.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=b4b52975f06372beaf9500817ac5e53f 2500w`})}),`\n`,_jsx(Heading,{level:`2`,id:`rule-types`,children:`Rule types`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Type`}),_jsx(_components.th,{children:`What it does`}),_jsx(_components.th,{children:`Example`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Local`})}),_jsx(_components.td,{children:`Listens on your machine and forwards to a destination reached from the SSH host`}),_jsxs(_components.td,{\"data-numeric\":`true`,children:[_jsx(_components.code,{children:`127.0.0.1:2200`}),` → `,_jsx(_components.code,{children:`127.0.0.1:22`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Remote`})}),_jsx(_components.td,{children:`Listens on the SSH host and forwards to a destination on your machine`}),_jsx(_components.td,{children:`Expose a local dev server on the remote host`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Dynamic SOCKS5`})}),_jsx(_components.td,{children:`Runs a SOCKS5 proxy on your machine and routes any TCP connection through the SSH host`}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`127.0.0.1:1080`})})]})]})]}),`\n`,_jsxs(_components.p,{children:[`A rule always goes through a saved host (the `,_jsx(_components.strong,{children:`SSH Host`}),`), using that host’s stored credentials. You don’t need an open terminal tab: YourSSH connects to the host on its own, and through its `,_jsx(_components.a,{href:`/user-guide/hosts`,children:`connection chain`}),` if it has one.`]}),`\n`,_jsx(Heading,{level:`2`,id:`create-a-rule`,children:`Create a rule`}),`\n`,_jsxs(Steps,{children:[_jsx(Step,{title:`Open the editor`,children:_jsxs(_components.p,{children:[`Go to `,_jsx(_components.strong,{children:`Port Forwarding`}),` and click `,_jsx(_components.strong,{children:`New rule`}),`. The `,_jsx(_components.strong,{children:`New Port Forward Rule`}),` panel opens on the right.`]})}),_jsxs(Step,{title:`Name the rule and pick a type`,children:[_jsxs(_components.p,{children:[`Enter a `,_jsx(_components.strong,{children:`Label`}),`, then choose the `,_jsx(_components.strong,{children:`Type`}),`: `,_jsx(_components.strong,{children:`Local`}),`, `,_jsx(_components.strong,{children:`Remote`}),` or `,_jsx(_components.strong,{children:`Dynamic SOCKS5`}),`.`]}),_jsx(Frame,{caption:`The type menu.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=0e778c7e9af82781825d6cfc2b604ad1`,alt:`Type dropdown with Local, Remote and Dynamic SOCKS5`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/06-type-menu.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=4ee067845a67143acf1ef647d18c422c 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=e5e3319be26b3acec4b525c3083988ae 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=a64b1c374832ec1b4877150dfa26541e 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=f1f051a0eedc9f1a9fbb9477348c07aa 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=5023112469884ea2c799361cefe08375 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/06-type-menu.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=f09e2dcb0077f6ebf3fa36277da0eb4f 2500w`})})]}),_jsx(Step,{title:`Set the addresses`,children:_jsxs(_components.p,{children:[`Fill in `,_jsx(_components.strong,{children:`Local Host`}),` and `,_jsx(_components.strong,{children:`Port`}),` (the address that listens on your machine). For `,_jsx(_components.strong,{children:`Local`}),` and `,_jsx(_components.strong,{children:`Remote`}),` rules, also fill in `,_jsx(_components.strong,{children:`Remote Host`}),` and `,_jsx(_components.strong,{children:`Port`}),` for the destination. A `,_jsx(_components.strong,{children:`Dynamic SOCKS5`}),` rule needs only the local address, so the remote fields disappear.`]})}),_jsx(Step,{title:`Choose the SSH host`,children:_jsxs(_components.p,{children:[`Pick the `,_jsx(_components.strong,{children:`SSH Host`}),` the tunnel runs through. The field is marked optional so you can save a draft, but a rule without a host can’t start. It reports `,_jsx(_components.strong,{children:`Select an SSH host first`}),`.`]})}),_jsx(Step,{title:`Optionally auto-start`,children:_jsxs(_components.p,{children:[`Tick `,_jsx(_components.strong,{children:`Auto-start on launch`}),` to bring the tunnel up each time YourSSH starts.`]})}),_jsx(Step,{title:`Save`,children:_jsxs(_components.p,{children:[`Click `,_jsx(_components.strong,{children:`Add Rule`}),`.`]})})]}),`\n`,_jsx(Frame,{caption:`A local rule filled in: localhost port 2200 to port 22 on the remote side, through Demo Server.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=6955aa232bca7744513542d0d70df971`,alt:`New Port Forward Rule panel with a local rule filled in`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/04-local-rule-filled.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=aa434906132777724e87e71284e6c93f 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=1ada6a59636908434bbc38d43583586c 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=cc1ebc82f50ac072fe49d1edfd1a137f 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=108c19a59b18f41c8370d785b2bdb009 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=c0d1df44d58fb5c1860ef74a7c24deee 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/04-local-rule-filled.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=c495561de74f41523f6531da287326cd 2500w`})}),`\n`,_jsx(Frame,{caption:`A dynamic SOCKS5 rule has no remote host or port.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=0e07ada71f287c6d9f7e723d7d2a7b77`,alt:`New Port Forward Rule panel with Dynamic SOCKS5 selected`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/07-dynamic-rule-filled.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=56c03348d5a308f6c76f828a71a5e5c8 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=f72050af3c09656a52bb99db04b3255e 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=5527221d84d1daf33fba59af33c039ca 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=28ffd60756f5165a00542d31efbe3d65 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=ac1596a07604bef91dfed2fae61b0f6b 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/07-dynamic-rule-filled.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=b7d2f94299084d21818a83fa270a8d9a 2500w`})}),`\n`,_jsx(Heading,{level:`3`,id:`validation`,children:`Validation`}),`\n`,_jsx(_components.p,{children:`The editor checks the form when you save:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Label`}),`, `,_jsx(_components.strong,{children:`Local Host`}),` and, for local and remote rules, `,_jsx(_components.strong,{children:`Remote Host`}),` can’t be empty. A missing value shows `,_jsx(_components.strong,{children:`Required`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Each `,_jsx(_components.strong,{children:`Port`}),` must be a number from 1 to 65535. Anything else shows `,_jsx(_components.code,{children:`1–65535`}),` under the field.`]}),`\n`]}),`\n`,_jsx(Frame,{caption:`A port of 70000 is rejected.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=164397e36577b03bcc31adaf64b82792`,alt:`Port field highlighted in red with the message 1–65535`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/03-validation-port.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=672440d3387105c4346a2ea3499b88c7 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=88e1878b4e0717ada62a88f86cbb61b5 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=3d35cfaad6e72cd4bceb9fbc55d6dd7a 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=940fa6d9bef8160623f4f6b5266cf706 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=942d8113ee3782a05446ef1ad43b5530 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/03-validation-port.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=1440d7d3ee53b5eed710f2b22c2c6e60 2500w`})}),`\n`,_jsx(Heading,{level:`2`,id:`start-and-stop`,children:`Start and stop`}),`\n`,_jsx(_components.p,{children:`Each rule has a button on the right: the play button starts it and the stop button stops it. Several tunnels can run at once, and each one is independent.`}),`\n`,_jsx(_components.p,{children:`The status dot on the left shows the state:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Dot`}),_jsx(_components.th,{children:`State`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Grey`}),_jsx(_components.td,{children:`Idle`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Amber`}),_jsxs(_components.td,{children:[`Connecting, or reconnecting (the rule also shows `,_jsx(_components.strong,{children:`reconnecting…`}),`)`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Green`}),_jsx(_components.td,{children:`Active`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Red`}),_jsx(_components.td,{children:`Error. The message appears under the rule, for example that a port is already in use`})]})]})]}),`\n`,_jsxs(_components.p,{children:[`An active rule shows a live connection count such as `,_jsx(_components.strong,{children:`1 conn`}),`.`]}),`\n`,_jsx(_components.p,{children:`If a rule fails to start, check the message under it. Common causes are a local port already in use, no SSH host selected, or the host no longer existing.`}),`\n`,_jsx(Heading,{level:`2`,id:`auto-reconnect`,children:`Auto-reconnect`}),`\n`,_jsxs(_components.p,{children:[`If the SSH connection drops while a tunnel is running, the rule switches to `,_jsx(_components.strong,{children:`reconnecting…`}),` and YourSSH reconnects with exponential backoff, starting at 2 seconds and doubling up to 30 seconds. Local listeners stay bound while it retries, so clients keep the same local port. Stopping the rule cancels the retry.`]}),`\n`,_jsx(Heading,{level:`2`,id:`edit-duplicate-and-delete`,children:`Edit, duplicate and delete`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Click a rule, or right-click and choose `,_jsx(_components.strong,{children:`Edit`}),`, to change it. The panel title is `,_jsx(_components.strong,{children:`Edit Port Forward Rule`}),` and the button is `,_jsx(_components.strong,{children:`Save`}),`. If the rule is running, stop and start it again to apply the change.`]}),`\n`,_jsxs(_components.li,{children:[`Right-click and choose `,_jsx(_components.strong,{children:`Duplicate`}),` to copy a rule. The copy is named `,_jsx(_components.code,{children:`… (copy)`}),` and never auto-starts.`]}),`\n`,_jsxs(_components.li,{children:[`Hover a rule and click the trash icon, or right-click and choose `,_jsx(_components.strong,{children:`Delete`}),`. YourSSH asks `,_jsx(_components.strong,{children:`Delete rule?`}),` first, naming the label and endpoints, with `,_jsx(_components.strong,{children:`Cancel`}),` selected by default. After you confirm, a running rule is stopped and removed. Deleting a host also stops the tunnels that use it.`]}),`\n`]}),`\n`,_jsx(Frame,{caption:`Clicking a rule opens it in the editor.`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=5e0fae2b092a59fa9df21f3b4747fd3d`,alt:`Edit Port Forward Rule panel next to the rule list`,\"data-og-width\":`1440`,width:`1440`,\"data-og-height\":`868`,height:`868`,\"data-path\":`images/08-port-forwarding/10-rule-editor.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=280\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=ab0b32ed6fd41652d40d476f5eefb01e 280w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=560\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=49e919e47519f5c595787edd5c8992c5 560w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=840\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=0bda63211ad9c9eefa51a06efed03458 840w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=1100\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=4df6a21b905a0368399ec970a1cfe4eb 1100w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=1650\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=2137a62dab82bda58986febd38314b6f 1650w, https://mintcdn.com/sen-f208ff9e/KwGOqbG40_L2ILah/images/08-port-forwarding/10-rule-editor.png?w=2500\u0026fit=max\u0026auto=format\u0026n=KwGOqbG40_L2ILah\u0026q=85\u0026s=673f2fdc185690880a76e8f972da60da 2500w`})}),`\n`,_jsx(Heading,{level:`2`,id:`example-reach-a-database-on-the-ssh-host`,children:`Example: reach a database on the SSH host`}),`\n`,_jsx(_components.p,{children:`To connect a SQL client to a PostgreSQL server that only listens on the SSH host:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Value`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Label`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`Postgres`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Type`}),_jsx(_components.td,{children:_jsx(_components.strong,{children:`Local`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Local Host / Port`}),_jsxs(_components.td,{\"data-numeric\":`true`,children:[_jsx(_components.code,{children:`127.0.0.1`}),` / `,_jsx(_components.code,{children:`5432`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Remote Host / Port`}),_jsxs(_components.td,{\"data-numeric\":`true`,children:[_jsx(_components.code,{children:`127.0.0.1`}),` / `,_jsx(_components.code,{children:`5432`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`SSH Host`}),_jsx(_components.td,{children:`your database host`})]})]})]}),`\n`,_jsxs(_components.p,{children:[`Start the rule, then point your client at `,_jsx(_components.code,{children:`127.0.0.1:5432`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`use-tunnels-in-web-tools`,children:`Use tunnels in Web Tools`}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.strong,{children:`Web Tools`}),` plugin has a `,_jsx(_components.strong,{children:`Port Tunnels`}),` tool that works with these forwarded ports, so you can open a tunnelled web service in the in-app browser. See `,_jsx(_components.a,{href:`/user-guide/web-tools`,children:`Web Tools`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`related-pages`,children:`Related pages`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/user-guide/hosts`,children:`Hosts`}),` for saved hosts and connection chains.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/user-guide/sftp`,children:`SFTP`}),` and `,_jsx(_components.a,{href:`/user-guide/terminal`,children:`Terminal`}),` use the same SSH connection settings.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/user-guide/devops`,children:`DevOps Hub`}),` for Cloudflare tunnels and other tunnel tools.`]}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Port forwarding","description":"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.","icon":"arrow-left-right","href":"/user-guide/port-forwarding"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Rule types","slug":"rule-types","depth":2,"children":[]},{"title":"Create a rule","slug":"create-a-rule","depth":2,"children":[{"title":"Validation","slug":"validation","depth":3,"children":[]}]},{"title":"Start and stop","slug":"start-and-stop","depth":2,"children":[]},{"title":"Auto-reconnect","slug":"auto-reconnect","depth":2,"children":[]},{"title":"Edit, duplicate and delete","slug":"edit-duplicate-and-delete","depth":2,"children":[]},{"title":"Example: reach a database on the SSH host","slug":"example-reach-a-database-on-the-ssh-host","depth":2,"children":[]},{"title":"Use tunnels in Web Tools","slug":"use-tunnels-in-web-tools","depth":2,"children":[]},{"title":"Related pages","slug":"related-pages","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"sen-f208ff9e","siteName":"YourSSH","title":"Port forwarding - YourSSH","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-13T08:54:47.032Z","originalFileLocation":"user-guide/port-forwarding.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\">\u003cmeta data-mint-head name=\"application-name\" content=\"YourSSH\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Port forwarding - YourSSH\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"YourSSH\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://sen-f208ff9e.mintlify.site/_mintlify/api/og/v2?division=Connections\u0026amp;title=Port+forwarding\u0026amp;description=Create+local%2C+remote+and+dynamic+SOCKS5+SSH+tunnels%2C+start+them+on+launch+and+keep+them+alive.\u0026amp;theme=9c28b55d71a4be955ba27112\u0026amp;signature=f33262a46b0865be4e7e0e253cb143c4b3901382465ad6cc7bde28c545de13f3\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Port forwarding - YourSSH\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://sen-f208ff9e.mintlify.site/_mintlify/api/og/v2?division=Connections\u0026amp;title=Port+forwarding\u0026amp;description=Create+local%2C+remote+and+dynamic+SOCKS5+SSH+tunnels%2C+start+them+on+launch+and+keep+them+alive.\u0026amp;theme=9c28b55d71a4be955ba27112\u0026amp;signature=f33262a46b0865be4e7e0e253cb143c4b3901382465ad6cc7bde28c545de13f3\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/sen-f208ff9e/SKoU7AxwHJ7tyeF-/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"YourSSH\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#E87C08\">\u003clink data-mint-head rel=\"canonical\" href=\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/user-guide/port-forwarding.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://sen-f208ff9e.mintlify.app/#organization\",\"name\":\"YourSSH\",\"url\":\"https://sen-f208ff9e.mintlify.app\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/sen-f208ff9e/qEqMDfcJBQhRyoaC/logo/light.svg?fit=max\u0026auto=format\u0026n=qEqMDfcJBQhRyoaC\u0026q=85\u0026s=7bf37a0c27b7602b53d522578cdb816e\"}},{\"@type\":\"WebSite\",\"@id\":\"https://sen-f208ff9e.mintlify.app#website\",\"name\":\"YourSSH\",\"url\":\"https://sen-f208ff9e.mintlify.app\",\"publisher\":{\"@id\":\"https://sen-f208ff9e.mintlify.app/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding#webpage\",\"url\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding\",\"name\":\"Port forwarding\",\"description\":\"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\",\"dateModified\":\"2026-11-13T08:54:47.032Z\",\"isPartOf\":{\"@id\":\"https://sen-f208ff9e.mintlify.app#website\"},\"breadcrumb\":{\"@id\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Connections\",\"item\":\"https://sen-f208ff9e.mintlify.app/user-guide/hosts\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Port forwarding\",\"item\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding#article\",\"headline\":\"Port forwarding\",\"name\":\"Port forwarding\",\"description\":\"Create local, remote and dynamic SOCKS5 SSH tunnels, start them on launch and keep them alive.\",\"url\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding\",\"mainEntityOfPage\":{\"@id\":\"https://sen-f208ff9e.mintlify.app/user-guide/port-forwarding#webpage\"},\"dateModified\":\"2026-11-13T08:54:47.032Z\",\"publisher\":{\"@id\":\"https://sen-f208ff9e.mintlify.app/#organization\"},\"isPartOf\":{\"@id\":\"https://sen-f208ff9e.mintlify.app#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"YourSSH\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"YourSSH\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/user-guide/port-forwarding.md","siteName":"YourSSH","nav":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/YoursshLabs/yourssh"},{"anchor":"Releases","icon":"download","href":"https://github.com/YoursshLabs/yourssh/releases"}]},"tabs":[{"tab":"User guide","groups":[{"group":"Get started","pages":[{"title":"Introduction","icon":"terminal","href":""},{"title":"Installation","icon":"download","href":"/installation"},{"title":"Quickstart","icon":"rocket","href":"/quickstart"}]},{"group":"Connections","pages":[{"title":"Hosts","icon":"server","href":"/user-guide/hosts"},{"title":"Host keys","icon":"shield-check","href":"/user-guide/host-keys"},{"title":"Terminal","icon":"terminal","href":"/user-guide/terminal"},{"title":"Terminal sharing","icon":"screen-share","href":"/user-guide/terminal-sharing"},{"title":"Bulk actions","description":"Select several hosts to open tabs, run one command everywhere in parallel, or push files to all of them.","icon":"layers","href":"/user-guide/bulk-actions"},{"title":"Port forwarding","icon":"arrow-left-right","href":"/user-guide/port-forwarding"}]},{"group":"Files","pages":[{"title":"SFTP","description":"Browse and transfer files between your computer and remote hosts in a dual-panel file manager.","icon":"folder","href":"/user-guide/sftp"}]},{"group":"Remote desktop","pages":[{"title":"RDP remote desktop","icon":"monitor","href":"/user-guide/rdp"},{"title":"VNC remote desktop","icon":"cast","href":"/user-guide/vnc"}]},{"group":"Security","pages":[{"title":"Keychain and credentials","icon":"key","href":"/user-guide/keychain"},{"title":"Session recording","icon":"video","href":"/user-guide/recording"},{"title":"Audit log","icon":"scroll-text","href":"/user-guide/audit-log"}]},{"group":"Tools","pages":[{"title":"Snippets","icon":"code","href":"/user-guide/snippets"},{"title":"AI assistant","icon":"bot","href":"/user-guide/ai-chat"},{"title":"DevOps Hub","icon":"rocket","href":"/user-guide/devops"},{"title":"Web tools","icon":"wrench","href":"/user-guide/web-tools"},{"title":"Command line and links","icon":"square-terminal","href":"/user-guide/cli"}]},{"group":"Settings and sync","pages":[{"title":"Settings","icon":"settings","href":"/user-guide/settings"},{"title":"Sync and device transfer","icon":"refresh-cw","href":"/user-guide/sync"},{"title":"YourSSH for Android","icon":"smartphone","href":"/user-guide/mobile"}]}]},{"tab":"Developer guide","pages":[{"title":"Developer guide","href":"/developer-guide/architecture"}]},{"tab":"Release notes","pages":[{"title":"Release notes","href":"/release-notes"}]}]},"basePath":"","title":"Port forwarding - YourSSH","buildId":"dpl_8hoxaqFTU7hTr6A2fUraxAyjuiZo","deploymentId":"dpl_8hoxaqFTU7hTr6A2fUraxAyjuiZo","dynamics":["07c022d89b","a74be98ba7"],"chunks":["Frame-Dmj010Ph.js","DynamicMarkdown-GHvayGOn.js","zoom-image-lightbox-8gCTkA22.js","lightbox-handle-r17bVUz3.js"]}