Claude Code Usage Guide

· 3 min read

After Cursor gained popularity, Claude Code emerged as another powerful tool. Who would have thought that coding in the terminal could be so impressive? When I saw it trending, I was curious and decided to try it out. I hit some snags initially, but after some tinkering, I finally got it working—and I must say, it’s really great. Here I’ll document the basic usage.

Prerequisites

  • Network access: Since Claude AI service is hosted overseas, if you have trouble accessing the web version, Claude Code will face the same issues. It’s recommended to resolve network connectivity first.
  • Virtual credit card or non-China Apple account: Either one will work. The specific reasons are mentioned below.

Claude Code Paid Usage

Claude Code is a paid service with two usage options:

  1. Claude subscription users, such as Claude Pro or higher Max subscriptions:
    • I personally find Apple App Store subscription the most convenient. For example, I purchase gift cards from Apple’s official website, then log into a US Apple account on my iPhone to subscribe directly. For details on how to purchase apps in the US region, you can refer to US Apple ID Payment Issues.
  2. Anthropic Console account: Directly bind a credit card for pay-as-you-go billing. If you don’t have a US credit card, you’ll need to use a virtual credit card. I previously used nobepay, but they’ve stopped accepting new card applications, so I won’t recommend it here.

I personally chose the Claude Pro subscription since it includes other features as well. My GPT subscription happened to expire, so I decided not to renew GPT for now.

https://static.1991421.cn/2025/2025-08-01-181802.jpeg

Claude Installation

For installation, simply use the following command:

npm install -g @anthropic-ai/claude-code

Terminal Proxy

  1. PC global proxy
  2. Shell proxy configuration
    • Set environment variables in your terminal profile (~/.bashrc or ~/.zshrc) using the following commands:

    export http_proxy=http://127.0.0.1:6152 export https_proxy=$http_proxy export all_proxy=$http_proxy export HTTPS_PROXY=http://127.0.0.1:6152 alias disproxy=‘unset http_proxy https_proxy all_proxy’

Usage

Basic usage of Claude is quite simple:

  1. Type claude, and on first use, you’ll enter the login process. Choose the appropriate method to log in.
    https://static.1991421.cn/2025/2025-08-02-230811.jpeg
  2. Enter interactive mode, directly describe your problem, and Claude will automatically identify and make modifications. You can continue this process iteratively.

For advanced usage, I recommend checking the official documentation.

Usage Monitoring

In interactive mode, type cost to view usage. If you’re a Pro subscription user, you won’t see specific usage details, but you’ll get notifications if you exceed limits.

Final Thoughts

Currently, the Claude Code experience is quite good. While there may be some network issues when used in China, it’s overall very convenient. I hope this guide helps those who need it.