---
title: "ezgh login"
description: "Log in with your EZGH Cloud account (OAuth 2.1)."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ezgh login

{/* Generated by ezgh-cli's internal/tools/clidocs from the ezgh command tree. Don't edit: change the command's help in ezgh-cli and regenerate. */}

```sh
ezgh login [flags]
```

Log in with your EZGH Cloud account. By default this opens your browser (authorization code with PKCE, through a redirect to a port on 127.0.0.1); `--device` prints a URL and a code to enter on any other device instead, for SSH sessions and machines without a browser.

The login belongs to the profile (`--profile`, `EZGH_PROFILE`, or the default profile), which is created if it doesn't exist. Its tokens go in the OS keychain, or a file only you can read where there's no keychain. The access token is refreshed automatically.

## Flags

| Flag | Type | Default | Description |
| --- | --- | --- | --- |
| `--device` | boolean |  | log in with a code on another device (no browser needed here) |
| `--no-browser` | boolean |  | print the login URL instead of opening a browser |

This command also takes the [global flags](/cli/reference#global-flags).

Source: https://docs.ezghcloud.com/cli/reference/login/index.mdx
