gitwtfhub

wtf is itchat?

littlecodersh/itchat — explained in plain English

Analysis updated 2026-05-18

26,468PythonAudience · developerComplexity · 2/5LicenseSetup · moderate

TL;DR

Python library to automate WeChat messaging, file transfers, and chatbots using your personal account via code instead of manual interaction.

Mindmap

mindmap
  root((repo))
    What it does
      Send and receive messages
      Automate replies
      Handle files and images
    How it works
      QR code login
      Session persistence
      Python code control
    Use cases
      Customer support bots
      Notification systems
      File sharing automation
    Tech stack
      Python
      WeChat web API
    Audience
      Chinese market builders
      Automation developers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Why would anyone build with this?

REASON 1

Build a customer support chatbot that automatically responds to WeChat messages on your behalf.

REASON 2

Create a notification system that sends alerts and updates to users via WeChat.

REASON 3

Automate file sharing and document distribution through WeChat group chats.

REASON 4

Set up a bot that monitors mentions in group chats and replies with custom logic.

What's in the stack?

PythonWeChat API

How it stacks up

littlecodersh/itchatungoogled-software/ungoogled-chromiumfacebookresearch/detectron
Stars26,46826,47226,389
LanguagePythonPythonPython
Setup difficultymoderatemoderatehard
Complexity2/52/55/5
Audiencedevelopergeneralresearcher

Figures from each repo's GitHub metadata at analysis time.

How do you spin it up?

Difficulty · moderate Time to first run · 30min

Requires WeChat account setup and API credentials/authentication configuration.

Use freely for any purpose including commercial, as long as you keep the copyright notice.

Wtf does this do

ItChat is a Python tool that lets developers control a WeChat personal account programmatically, meaning you can write code that automatically sends and receives WeChat messages, files, and images on your behalf. It's essentially a way to build a WeChat chatbot or automation tool using your own personal WeChat account rather than an official business account. With just a few lines of Python code, you can set up a bot that reads incoming messages and replies automatically, forwards files, responds to mentions in group chats, or performs any custom logic you define. The login process works by scanning a QR code once, and the session can be saved so you don't need to scan again each time. The README is primarily in Chinese, which reflects its audience, it was built for Chinese developers working with WeChat, which is the dominant messaging platform in China with over a billion users. For a founder or vibe coder, this is most relevant if you're building something for the Chinese market and need WeChat automation, like a customer support bot, a notification system, or an automated file-sharing tool delivered via WeChat. It's a Python library, so you'd need a developer (or to use an AI coding tool) to actually implement it. Note that this uses the unofficial WeChat web API, which Tencent (WeChat's parent company) has restricted over time, so the library may have reliability limitations depending on account type and WeChat's current policies.

Yoink these prompts

Prompt 1
Show me how to set up a basic WeChat bot using itchat that replies 'hello' to any incoming message.
Prompt 2
How do I save and restore a WeChat login session in itchat so I don't have to scan the QR code every time?
Prompt 3
Write a Python script using itchat that forwards all messages from one WeChat contact to another contact automatically.
Prompt 4
How can I use itchat to send a file or image to a specific WeChat group programmatically?
Prompt 5
Create an itchat bot that listens for messages containing a keyword and replies with a custom response.

Frequently asked questions

wtf is itchat?

Python library to automate WeChat messaging, file transfers, and chatbots using your personal account via code instead of manual interaction.

What language is itchat written in?

Mainly Python. The stack also includes Python, WeChat API.

What license does itchat use?

Use freely for any purpose including commercial, as long as you keep the copyright notice.

How hard is itchat to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is itchat for?

Mainly developer.

View the repo → Decode another repo

This repo across BitVibe Labs

Don't trust strangers blindly. Verify against the repo.