Krita Stable Diffusion plugin for Windows and LInux

Hi all,

I have released a Stable Diffusion plugin for Krita for Windows and Linux that allows you to use Stable Diffusion in Krita without installing any dependencies.

See installation instructions and get download link here

Some of the features of this plugin

  • No need to install all the dependencies of Stable Diffusion. You don’t even need Python
  • Non-blocking image generation - queue up images and keep working in Krita while they generate in the background.
  • NSFW and watermark toggle

Planned features

  • More models for improved image generation
  • Ability to run on CPU (currently GPU support only)
  • Improved installation process
  • Cloud service

You may encounter bugs as this is an alpha build, the first Windows version of the plugin and I’m the only developer at the moment. If you do, please open a bug report on Github.

I have put in many long days to make this happen and will continue to do so. If you like my work, please star the project, and if you’re feeling nice consider sponsoring me on GitHub so that I can keep delivering quality software and support to you.


Looks cool. Can you give any indication of what sort of download size in terms of Gb this will need to get running?

Says 1.4 GB for the Linux version. It mentions an addition download (the model), so I’m not sure what the total size would be. Umm… Maybe I should just let the author answer… :sweat_smile:

edit: I think the model might be around 4GB

I’m interested in having a play myself but I think my rig is far short of the minimum specs. I guess our robot overlords will just have to go on without me… :smiling_face_with_tear:

@Souphead @Mythmaker

The unzipped plugin is 5.79gigs

The stablediffusion directory which resides in your Home directory and contains the models is over 7.5 gigs with the small model. You should probably have at least 15 gigs reserved in total (possibly more for the large model). I will post accurate numbers to the plugin repo when i get a time.

1 Like

I’m at the download the model phase in the Windows script so not complete yet. There is one important step missing from your instructions. After creating a account, and confirm with your email, you must find the stable-diffusion-v-1-4-original model from the models tab (IT MUST BE THE ORIGINAL v1.4 ONE NOT THE ONE WITHOUT THE “ORIGINAL” WORD IN IT) and must agree to the licensing term in it before the script will be able to download the model.

4 more gigs from a bandswidth short user will take some time for me but otherwise everything is working perfectly.

1 Like

Thanks for your feedback. I will add this to the installation steps. I am actually working to improve the installation process overall and will be decoupling the stable diffusion from the plugin itself. I’ll post to these forums when the update drops.

1 Like

Everything downloaded and set up. Problem is when I actually try to generate an image I get the following:

You said that the CUDA drivers might be needed. Is this what needing the drivers looks like or is this some other problem?

It looks like stable diffusion generated your image but didn’t have a connection established with the Krita plugin which caused the “socket timeout” error. If you run into this issue again:

close the server (sdrunner.exe), restart Krita and then restart the server using the new PID displayed in the Krita plugin.

the newest version of the plugin (which will be released soon) solves several bugs including issues with connectivity. You will also no longer need to start the server using a PID. I’ll post here when it is ready.

If you continue to run into issues please consider opening a bug report on github

@Souphead I also notice from your screenshot that you do not have a 512x512 document opened in Krita. Please be sure to open a document for your image to load into prior to generating it.

I will add this to the instructions in the meantime, but I plan to disable plugin interactions if a document hasn’t been created yet.

Additionally, you should still be able to access your image from the stablediffusion/txt2img folder which is in the home folder of your computer.

Ahh, that was it. Get a blank canvas us before generating. So here the proof in my first image - a cat (with a wonky eye).

Brilliant, brilliant, brilliant! Seems you have produced the easiest way to get Stable Diffusion up and running I have found.

1 Like

I’m happy to see it working for you.
The upcoming version makes some major improvements. i’m working hard to get it out the door as fast as possible (without breaking anything). if you have suggestions or ideas feel free to post them here, on github or join our discord server


With the ability to use CPU instead of GPU, this means it use computer memory instead of graphic card memory?
Then it’s available for everyone that don’t have a big graphic card?


Correct - most of the image generating models do not need to be run on a GPU, its just faster.

I was able to use min-dalle on a Pi 3. it took around 5 minutes to generate an image.


I have 24CPU and 64GB ram, even if it’s not fast as with a GPU it should be ok then? :sweat_smile:


The next release will have CPU support - so you try it when it comes out and tell me :smiley:

1 Like

Then I can finally test SD with my AMD graphics, because I also have a decent PC with 24 CPU’s and plenty of RAM.


Thank you for this plugin.

I’m trying installing on Linux. I got the following output.

./install: line 61: krita: command not found
Found Krita version }

Krita version is not set, failed to install

Thank you very much for your work.
Can I ask you: I installed this plugin and when I tried to generate an image, I got this message. Probably I did something wrong? What did i do wrong, how do you think?
Sorry if the question is stupid. Anyway thanks for what you do

@Mike_Rms did you manage to solve it. i am on ubuntu 20 and have exact same problem. even when krita (app image) started from shell with python env activated

No unfortunately, I could not figure out what the problem is. So I just installed the desktop version and use it.

1 Like