Create a second WeChat instance on macOS for running two accounts simultaneously.
Core Method
The underlying mechanism is simple — macOS distinguishes apps by their bundle identifier. By copying WeChat, changing the copy's bundle ID, and re-signing it locally, macOS treats the copy as a separate app that can run alongside the original:
- Copy
/Applications/WeChat.appto~/Applications/WeChat-2.app. - Change the copy's
CFBundleIdentifier(e.g., tocom.tencent.xin2). - Re-sign the copy with
codesign --force --deep --sign -. - Launch the copy via its executable directly.
No third-party injection tools or modified binaries required.
Prerequisites
- macOS 12+ with WeChat installed at
/Applications/WeChat.app - Python 3.10+ (system python works)
- Pillow (
pip3 install Pillow) — required only forrecolor-icon - Xcode Command Line Tools (
xcode-select --install) forcodesign,iconutil,sips
Locating the Script
The helper script lives at scripts/wechat_dual_open.py relative to this skill
directory. Different agents install skills to different paths. Construct the
script path dynamically:
# Auto-detect skill directory
SKILL_DIR="$(dirname "$(find ~ -path '*/mac-wechat-dual-open/SKILL.md' -maxdepth 4 2>/dev/null | head -1)")"
SCRIPT="$SKILL_DIR/scripts/wechat_dual_open.py"
Quick Commands
python3 "$SCRIPT" status # Check current state
python3 "$SCRIPT" create # Create the second WeChat
python3 "$SCRIPT" set-language --languages zh-Hans en # Set Chinese
python3 "$SCRIPT" recolor-icon --blue "#1296db" # Blue icon
python3 "$SCRIPT" launch # Start the second instance
python3 "$SCRIPT" repair # Fix bundle id, signing, language, caches
Default paths (override with --source-app, --target-app, --bundle-id):
- Source:
/Applications/WeChat.app - Target:
~/Applications/WeChat-2.app - Bundle ID:
com.tencent.xin2
Workflow
- Status first. Run
statusto see what already exists. - Create. If no second app exists, run
create. This copies the app, changes the bundle ID, sets Chinese language, removesCFBundleIconName, re-signs, and registers with Launch Services. - Language. If the second instance opens in English, run
set-language, then restart it. - Icon. Run
recolor-iconto change the WeChat green to a user-chosen blue. The script handles both the outerAppIcon.icnsand the embeddedWeChatAppEx.app/.../app.icns, removesCFBundleIconNameto avoid staleAssets.carentries, and sets a Finder custom icon when the Carbon-era tools (DeRez,Rez,SetFile) are available. - Launch. Run
launch. The second WeChat should appear with its own login window. Pin it to the Dock separately from the original.
Reliability & Tradeoffs
This is not an official method. Rate it roughly 6.5–7 / 10 for reliability:
- Works on many macOS + WeChat version combinations.
- No code injection or third-party tweaks — easy to inspect and undo.
- Breaks after WeChat updates. Re-run
create(orrepair) after updating the original WeChat. - Push notifications may be unreliable (APNs tied to original identity).
- Login state and Keychain are isolated per bundle ID.
- Ad-hoc signing may fail if WeChat adds stricter signature checks.
See references/reliability-and-risks.md for the full analysis.
Icon Pitfalls
WeChat stores icons in multiple locations. The script handles all of them:
| Location | What it affects |
|---|---|
Contents/Resources/AppIcon.icns |
Main app icon |
Contents/MacOS/WeChatAppEx.app/Contents/Resources/app.icns |
Embedded runtime icon |
Contents/Resources/Assets.car |
Asset catalog (handled via CFBundleIconName removal) |
Icon\r + Finder custom icon attr |
Finder "Applications" view |
If the user reports the icon is still green:
- They may be looking at
/Applications/WeChat.app(the original), not~/Applications/WeChat-2.app. Verify withopen -R ~/Applications/WeChat-2.app. - Dock caches per-process icons. Quit and relaunch WeChat-2.
- The Finder custom icon step requires
DeRez/Rez/SetFilewhich may not exist on macOS 13+. The script skips gracefully — icns replacement is usually sufficient.
Safety
- Never modify
/Applications/WeChat.app— all changes are scoped to the copy. - Ask before deleting an existing second app. Prefer
repairover delete/recreate. - The
codesignstep must run before adding a Finder custom icon, otherwise macOS rejects the bundle with "resource fork, Finder information, or similar detritus not allowed".
References & Attribution
- Original tutorial by @koffuxu (2026-04, blog post: "The most perfect solution for running two WeChat instances on Mac")
- Confirmed by @MinLiBuilds (2026-04)
- Icon recoloring uses HSV/HLS hue rotation via Pillow.
- Finder custom icon technique uses classic Carbon resource tools (
DeRez/Rez).