Overview
Forward a local port to a service container port. This allows you to access services running in your Qovery environment from your local machine. Port-forwarding requires the Port-forward permission on the service’s environment type. See Shell and Port-forward permissions.Command
--port flag specifying the port mapping in local_port:remote_port format. A single number, such as --port 5432, uses the same port on both sides.
Without an argument, the command targets the service in your context and asks you to confirm it, or to pick a service. You can also pass the Console URL of the service as the first argument. To find a pod name for --pod, run qovery list-pods.
Usage
Examples
Forward a Single Port
Forward Multiple Ports
Access PostgreSQL Database
Access Application API Locally
Use Cases
Database Access
Database Access
Forward database ports to run queries, migrations, or admin tools locally without exposing databases publicly.
Debugging Applications
Debugging Applications
Access application debug ports or admin interfaces that aren’t exposed publicly.
Local Development
Local Development
Connect your local development environment to remote services (databases, APIs, microservices).
API Testing
API Testing
Test APIs or services that aren’t publicly accessible.
Tips
Troubleshooting
Port Already in Use
If the local port is already in use:Connection Rejected
If each connection is rejected withPort-forward connection rejected: check your permissions or run 'qovery auth', run qovery auth first, as an expired session gives the same error. If the rejection persists, your role does not have the Port-forward permission on this environment type. Ask an organization admin to grant it. See Shell and Port-forward permissions.
Connection Drops
If the connection drops frequently:Command reference
Generated fromqovery port-forward --help (CLI v1.180.0). Every command also accepts -h, --help and the global flags.
qovery port-forward
Port forward a port to an application container
Usage
Related Commands
qovery shell- Execute commands in containerqovery log- View service logsqovery status- Check service status