Command Line Interface

Full Control fromthe Terminal

Quickly manage your servers, domains, and all services from the command line with Hosted Cloud CLI. Integrate into your scripts, set up automations.

Easy Installation
Secure Connection
Fast Operations
v3.2Latest Version
3Platform
50+Commands

Installation

Install with a single command for your operating system

$brew install hosted-cloud/tap/hcloud
Quick Start
$ hcloud auth login
? API Key: ********
✓ Authenticated as [email protected]

$ hcloud server list
ID          NAME             STATUS    IP              PLAN
srv_abc123  web-production   running   185.x.x.x      cloud-4vcpu-8gb
srv_def456  staging          running   185.x.x.y      cloud-2vcpu-4gb

$ hcloud server create --name api-server --plan cloud-4 --image ubuntu-22
✓ Server 'api-server' created successfully
  ID: srv_ghi789
  IP: 185.x.x.z

Command Reference

Discover the most commonly used commands

Server Management

hcloud server listList all servers
hcloud server create --name web --plan cloud-4 --image ubuntu-22Create new cloud server
hcloud server ssh webConnect to server via SSH
hcloud server resize web --plan cloud-8Upgrade server plan

Domain & DNS

hcloud domain listList domains
hcloud dns add example.com A www 185.x.x.xAdd DNS A record
hcloud ssl issue example.comGenerate SSL certificate

Database

hcloud db listList databases
hcloud db create --engine postgres --version 16 --plan db-2Create PostgreSQL database
hcloud db connect app-databaseConnect to database

Monitoring & Logs

hcloud monitor statusView system status
hcloud logs web --followFollow live logs
hcloud metrics web --period 24hView last 24 hours metrics

CLI Features

Powerful command line tool designed for developers

Fast Execution

Native binary written in Go. No dependencies required, runs in milliseconds.

Auto-Complete

Tab completion support in Bash, Zsh, and Fish shells. Auto-complete commands and parameters.

Multiple Profiles

Easily switch between multiple accounts and environments. Profile-based configuration.

Flexible Output

JSON, YAML, table, and minimal output formats. Pipe-friendly output suitable for scripts.

Script Support

Easily integrate into CI/CD pipelines and automation scripts. Non-interactive mode.

Secure Identity

API keys are securely stored in the OS keychain. Token rotation and 2FA support.

Frequently Asked Questions

Install the CLI Now

Install with a single command and start managing your infrastructure from the terminal in minutes.

CLI Tool | Hosted Cloud