1. Why You Need a Personal Image Host
An image host is a server that stores images and generates external URLs for online loading, widely used in web development. Mainstream options include ImgURL, SM.MS, Sina Weibo, imgtu, and Qiniu Cloud. These services fall into two camps: free ones are ad-heavy and unreliable, while paid ones are hard to justify for individual developers. As engineers, we should leverage open-source infrastructure to our advantage. GitHub, GitLab, and Gitee make excellent image hosts — clean, stable, and free. Since GitHub and GitLab have poor access speeds in mainland China, Gitee is the practical choice.
2. The Image Hosting Tool — PicGo
Even with a Gitee-based image host, manually pushing images via Git and then copying URLs from the repo is clunky compared to using a proper image hosting service. This is where PicGo comes in.
PicGo: A tool for quickly uploading images and retrieving their URLs.
In short, PicGo handles the push to remote and retrieves the external URL automatically, sparing you the manual work.
3. Setting Up a Gitee-Based Image Host
3.1 Create the Gitee Repository
Two things to keep in mind when creating the repo: it must be public (otherwise others can’t view your images), and you only need to initialize the master branch — all image hosting operations happen there.


3.2 Install and Configure PicGo
Download the installer: version: 2.3.0;
For Windows, grab this:

Launch the app and you’ll notice the image host settings don’t include Gitee out of the box — you need a plugin. Go to the plugin settings, search for gitee, and install gitee 2.0.5.
Plugin installation relies on
npm, soNode.jsmust be installed first.

After the plugin installs, restart the app. Open the image host settings and select Gitee. Here’s the configuration:
owner: Your Gitee username (donehub);
repo: Your Gitee image repository name (img-bed);
path: Directory for storing images (optional);
token: A private token generated on Gitee to authorize PicGo operations on your image host;
message: Default commit message is fine;

Configuration tips:
owner and repo are easy to mistype — just copy them directly from Gitee:

Generating a private token on Gitee:
Steps: Profile → Settings → Security → Private Token → Configure Permissions → Submit;
The token is shown only once, so save it somewhere safe.




3.3 Upload Images
Open the upload area and you’ll see PicGo supports four upload methods: drag-and-drop, file picker, clipboard paste, and URL upload. The returned URL comes in Markdown, HTML, and other formats.

Upload an image and, once it succeeds, open the album. The album lets you view all uploaded images, copy their URLs, and edit the link format.

4. Embedding PicGo into Typora
PicGo + Gitee works well, but manually uploading images and copying URLs is still friction. Since the image host exists to serve your writing, embedding PicGo directly into your editor makes sense.
Typora is a popular Markdown editor that supports embedded PicGo integration in version 0.9.98 and above. Once configured, dragging an image into the editor automatically uploads it to your image host and inserts the external URL.
Configuration: File → Preferences → Image → Upload image on insert → Upload settings

Open a Test.md file and drag an image into it. You’ll see a brief loading indicator, then the image uploads and the URL gets replaced automatically.
