You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/docs/configuration/env.md
+28-13Lines changed: 28 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,24 +35,39 @@ If you use `client_type: litellm`, set `OPENAI_API_KEY` or configure the LiteLLM
35
35
|`HYPERLIQUID_PRIVATE_KEY`|**Yes**| Ethereum private key for signing orders (`0x...`) |
36
36
|`HYPERLIQUID_TESTNET`| No |`true` to use testnet, `false` for mainnet (default: `false`) |
37
37
38
-
:::danger Private Key Security
39
-
- Never commit `.env` to any repository
40
-
- Never share your private key with anyone
41
-
- Loss of the private key means permanent loss of funds
42
-
- Use a dedicated trading wallet, not your main holdings wallet
38
+
### API Wallet Authorization
39
+
40
+
Hyperliquid supports **API wallets** (sub-wallets) for programmatic trading. This is the **recommended approach** — it keeps your main wallet's private key safe and lets you revoke access at any time.
41
+
42
+
#### Step 1 — Create an API Wallet
43
+
44
+
1. Open [https://app.hyperliquid.xyz/API](https://app.hyperliquid.xyz/API) with your **main wallet** connected
45
+
2. Click **Generate API Wallet** — Hyperliquid will create a new key pair
46
+
3. Copy and save the **private key** shown (it will not be shown again)
47
+
4. The API wallet address will now appear in your API Wallets list
48
+
49
+
:::tip Testnet
50
+
For testnet, use [https://app.hyperliquid-testnet.xyz/API](https://app.hyperliquid-testnet.xyz/API). Get free test funds from the [Testnet Faucet](https://app.hyperliquid-testnet.xyz/faucet).
0 commit comments