English | 中文
NX-ScreenUploader automatically sends screen captures (both images and videos) taken on your Nintendo Switch to Telegram and/or ntfy.sh so that you can more easily access and share them.
This project was forked from bakatrouble/sys-screenuploader and musse/sys-screen-capture-uploader and yuno-kojo/sys-screen-capture-uploader. It differs from the original project because no intermediate server is needed. The screen captures are directly uploaded to the Telegram or ntfy.sh or Discord.
- Automatically uploads screenshots and screen recordings taken on the Switch
- Multiple upload destinations: Telegram/Discord/ntfy.sh/Immich
- Custom Telegram Bot API URL support (for reverse proxy)
- Custom new screen capture check interval support
- Less memory usage compared to the original project (from ~1.852 MB to ~1.339 MB)
- No more fatal crashes when opening nxmenu in applet mode alongside other sysmodules
- Telegram: Uploads screen captures to a chat with your own Telegram bot. You can then easily access and share the captures from your Telegram.
- ntfy.sh: Uploads screen captures to a specified ntfy.sh topic. You can subscribe to this topic using the ntfy mobile app or web interface to receive the captures as notifications.
- Discord: Uploads screen captures to a specified channel in your Discord server using a Discord bot. You can then view and share the captures from that channel.
- Immich: Uploads screen captures to your self-hosted Immich instance using its API. You can then view and manage the captures from the Immich web interface or mobile app.
You need a Nintendo Switch running Atmosphere, a custom firmware which will allow you to run homebrew. Check this guide if you don't know how to hack your Switch.
You can choose to upload to Telegram, ntfy.sh, or both. Configure at least one upload destination.
At least one upload destination must be configured.
To use Telegram, you must create your own Telegram bot. It will send your Switch screen captures to you (and only to you) on a private chat.
- Create a Telegram bot. Choose any name and username of your preference. Note down its
API Token. - Send any message to your bot from the Telegram user that should receive the screenshots.
- Open
https://api.telegram.org/bot<your-bot-token>/getUpdateson your browser. You should see a single result with your message. Note down thechat ID(.result[0].message.chat.idinjqfilter notation).
ntfy.sh is a simple HTTP-based pub-sub notification service. You can use the public instance or host your own.
Note that ntfy.sh topics are public by default. Anyone who knows your topic name can publish or subscribe to it. Therefore, it's recommended to choose a unique and hard-to-guess topic name. You can also protect your topic with an access token.
- Choose a unique, hard-to-guess topic name (e.g.,
my-switch-captures-abcdefg) - (Optional) If you want to protect your topic, create an access token at ntfy.sh/account
- Subscribe to your topic using the ntfy mobile app or web interface (e.g.,
https://ntfy.sh/my-switch-captures-abcdefg)
To use Discord, you must create your own Discord APP and Bot. It will send your Switch screen captures to a specified channel in your server.
Discord configuration is a little more complex than Telegram and ntfy.sh.
Follow Creating a Bot Account to obtain your Bot Token and invite the bot to your server with the appropriate permissions (at least "Send Messages").
Then get the Channel ID of the channel where you want the screenshots to be sent. You can do this by enabling Developer Mode in Discord settings, then right-clicking on the desired channel and selecting "Copy Channel ID".
To use Immich, you must have a self-hosted Immich instance and create an API token for authentication. Grab it from https://my.immich.app/user-settings?isOpen=api-keys
Once you have prepared your upload destination(s), you can install the sysmodule on your Switch:
- Download the latest release and extract it somewhere.
- Copy
config/NX-ScreenUploader/config.ini.templatetoconfig/NX-ScreenUploader/config.iniand configure your upload destination(s):- For Telegram: Set
telegram = truein[general], then configurebot_tokenandchat_idin[telegram]section - For ntfy.sh: Set
ntfy = truein[general], then configuretopic(and optionallytoken) in[ntfy]section - For Discord: Set
discord = truein[general], then configurebot_tokenandchannel_idin[discord]section - For Immich: Set
immich = truein[general], then configureserver_urlandapi_keyin[immich]section - You can enable destinations simultaneously
- Optional: upload timeouts and retries can be adjusted in the
[upload]section, see Upload Tuning
- For Telegram: Set
- Copy the release contents to the root of your SD card.
config.ini ships with values that work well on a normal home network, so this section only matters when uploads time out or a destination throttles you. All keys belong to the [upload] section at the end of the file.
| Key | Default | Description |
|---|---|---|
image_connect_timeout / video_connect_timeout |
10 / 15 |
Seconds allowed for establishing the connection. |
image_idle_timeout / video_idle_timeout |
30 / 60 |
Abort the transfer when it stays below low_speed_limit for this many seconds. |
image_total_timeout / video_total_timeout |
60 / 300 |
Hard limit in seconds for a single attempt. |
low_speed_limit |
1 |
Bytes per second that still count as progress. |
image_max_attempts / video_max_attempts |
2 / 3 |
Total attempts per channel for one file, 1 disables retries. |
retry_base_ms |
1000 |
Delay before the first retry. |
retry_max_ms |
15000 |
Upper bound for the exponential backoff. |
retry_after_cap_ms |
60000 |
Upper bound for a Retry-After wait requested by the server. |
image_item_budget / video_item_budget |
0 |
Seconds a single file may occupy the upload queue, 0 means unlimited. |
How retries behave:
- Only failures that can succeed later are retried: timeouts, connection errors, HTTP 408/425/429 and 5xx. A 401, 403, 404 or 413 gives up immediately, so a wrong token or an oversized file does not waste minutes.
- Delays start at
retry_base_ms, double up toretry_max_msand carry a ±20% jitter. ARetry-Afterheader sent by the server takes precedence, capped atretry_after_cap_ms. - Retries are spread across the regular detection loop instead of blocking it, so the sysmodule keeps detecting new captures while a file waits for its next attempt. Once
*_max_attemptsrounds are used up (or the item budget is exhausted) the file is dropped and an error is logged. - Every attempt is bounded by its total timeout, so the worst case for one file is roughly
enabled_channels × attempts × total_timeout. Setvideo_item_budget(for example to600) to enforce a hard ceiling.
You can install devkitpro-pacman and then install the needed dependencies with:
sudo dkp-pacman -Syu
sudo dkp-pacman -S devkitA64 switch-dev switch-curl switch-zlibCheck the following links for additional details on how to set up your environment for Switch homebrew development:
To build the project, you also need
CMake.
bash scripts/build.sh
bash scripts/release.shOr manually:
mkdir build && cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=../devkita64-libnx.cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ONYou should now have a Makefile inside the build directory and can simply run make to build the project. The relevant binary file is NX-ScreenUploader.nsp.
After building the project, you can generate a release by running scripts/release.sh from the repository root. This will create the correct directory structure that should be copied to the root of your SD card and also a zip file containing all these files.
- bakatrouble/sys-screenuploader: project from which this project was forked;
- musse/sys-screen-capture-uploader: project from which this project was forked;
- yuno-kojo/sys-screen-capture-uploader: project from which this project was forked;
- vbe0201/libnx-template: homebrew template project;
- SunTheCourier/SwitchPresence-Rewritten: initial sysmodule code.