Script to backup and restore your joined subreddits, multireddits, followed users, saved posts, saved comments, hidden posts, upvoted posts and downvoted posts.
Reddit shadow banned my secondary account without specifying any reasons. Therefore, I wanted to transfer my 700+ subreddits, 50+ multireddits, 300+ followed users, 100+ saved posts and 150+ upvoted posts to a new account. I made this script to transfer all these data to my new account and start fresh. It's always good to have a backup of your account's user data because anyone can get banned on Reddit at any time without any justifiable reason.
-
Make sure you have python installed.
-
Download the latest release
-
Open a terminal inside the
reddit-backup-restore
folder and run:pip install -r requirements.txt
. -
Replace the placeholders inside
praw.ini
file.Note: To get
client_id
andclient_secret
, go here and create an app with these values. After creating the app you can see theclient_id
andclient_secret
. -
You need to create two apps, one on the account you want to backup and one on the account you want to restore.
This will create a backup.json
where all account_1_username
's user data will be stored.
python reddit.py backup account_1_username
Note: Followed multireddits will not be backed due to reddit's API limitation.
This will restore all account_1_username
's user data which was backed up to backup.json
to account_2_username
.
python reddit.py restore account_2_username
Note: By default, upvoted and downvoted posts will not be restored. Modifying upvotes and downvotes in bulk may trigger Reddit's automated vote manipulation detector, which may lead to permanent ban. Use at your own risk. You can modify the config.ini
to enable this feature.
If you want to unsubscribe all joined subreddits, unfollow all users, delete all multireddits, saved posts, saved comments and hidden posts, run:
python reddit.py clear account_username
Again, upvoted posts and downvoted posts will not be cleared by default. You can modify the config.ini
to enable this feature.
You can also delete all your posts and comments by modifying the config.ini
. By default, your posts and comments will not be deleted.
This script is provided as-is, without any guarantees or warranties. By using this script, you acknowledge and agree that the author will not be responsible or liable for any bans, data loss, or other issues that may arise. Use this script at your own risk. Always ensure you comply with Reddit's terms of service and guidelines when using this script.