You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3.5 KiB

Wallpaper Roulette

This is a small project I wrote because I got tired of my wallpapers way too fast.
This way I utilize the Konachan API to fetch random wallpapers and automatically apply them.

This was written with Windows 10 and Ubuntu 20.04 in mind.
So this might not run on your OS or OS version.


  • Python 3.5 or higher (download)
  • Python packages: Requests
  • Active internet connection


To install the required packages you can simply run:

python -m pip install -r requirements.txt

The requirements.txt file has all the required dependencies predefined

Build locally

To build this into a single executable I use PyInstaller.
And execute the following command:

pyinstaller --name "WallpaperRoulette" --icon "./icons/icon.ico"  --onefile


The images will always be downloaded to the locations below although
I have plans to implement a system that you will be able to change that.

Windows: %USERPROFILE%/Downloads/Wallpaper-Roulette
Ubuntu: ~/Downloads/Wallpaper-Roulette


With the CLI version I've also decided to remove the config file.
All the configuration has been replaced with arguments.


-h, --help
Shows the help menu with all the possible arguments.

-v, --version
Show version and information about this app.

-c, --clean
Remove previous downloaded images.

-s SERVICE, --service SERVICE
Which service being used to find images.

-t TAG, --tag TAG
Tag to be used for searching images.

-x WIDTH, --width WIDTH
Exact image size (Width).

-y HEIGHT, --height HEIGHT
Exact image size (Height).

-r RATING, --rating RATING
Image rating (may differ per API).


This will download an image with the tag swimsuit that is rated safe.

py -t swimsuit -r safe
py --tag swimsuit --rating safe

This will download an image with the tag christmas from that is rated explicit.

py -t christmas -r explicit -s
py --tag christmas --rating explicit --service

This will download an image with the tag kiss that is rated safe and cleans up previous downloaded images.

py -t kiss -r safe -c
py --tag kiss --rating safe --clean

This will download an image with the tag swimsuits with the dimensions 3840x2160
from that is rated questionable and cleans up previous downloaded images.

Note that the short argument for --height and --width are -x and -y.
This is because -h couldn't be used because --help is already using that.

py -t swimsuits -x 3840 -y 2160 -s -r questionable -c
py --tag swimsuits --width 3840 --height 2160 --service --rating questionable --clean

Planned features

  • Offline mode
    When no connection can be detected or the API is offline.
    It will use previous downloaded wallpapers.
  • Change download location
    With this version of the application, the download location is hardcoded.
    I will try to implement a nice way to make you able to change that without altering the code.