A lightweight Telegram bot that receives any file from your phone and saves it directly to your VPS โ replying with the exact path ready to paste.
Four steps from phone to path โ no cloud storage, no web UI, just your VPS.
/opt/uploader/inbox/ with a timestamped nameโ Telegram Bot API file size limit: 20 MB
Requires Node.js 18+ and a VPS. Takes about 5 minutes.
Make sure Node.js 18+ is installed, then install pm2 globally.
# Check Node version node -v # Install pm2 npm install -g pm2
Open Telegram, message @BotFather, send /newbot, and follow the prompts. Copy the token it gives you.
Then message @userinfobot to get your numeric user ID.
SSH into your VPS and run:
git clone https://github.com/CryptoPilot16/uploader /opt/uploader cd /opt/uploader npm install
Open the config and add your token and user ID:
nano ecosystem.config.js
// Set these two values: TELEGRAM_BOT_TOKEN: 'your-token-here', ALLOWED_USER_ID: 'your-user-id-here',
Start the bot and configure it to survive reboots.
pm2 start ecosystem.config.js pm2 save # Enable auto-start on reboot: pm2 startup # Copy and run the command pm2 prints pm2 save
Open Telegram, find your bot, and send it any photo or file. It should reply with a path like:
/opt/uploader/inbox/2026-04-08T12-30-45_photo.jpg
Nothing happened? Check the logs:
pm2 logs uploader
All commands are only accessible to your Telegram user ID.
| Command | Description |
|---|---|
| /help | Show available commands |
| /list | Show the last 10 files saved to inbox |
| /clear | Delete all files in inbox |
# View live logs pm2 logs uploader # Check status pm2 status # Restart after config change pm2 delete uploader && pm2 start ecosystem.config.js && pm2 save