How to Inpaint Stable Diffusion

Are you trying to modify your image on Stable Diffusion? Learn how to do it through the steps below.
How to Inpaint Stable Diffusion

Stable Diffusion generates accurate and reliable images through an image reference with its img2img model. It also goes beyond that by offering the ability to work on an existing image and modify and edit it through its exclusive inpaint tool, part of the img2img model.

In this guide, we will present a demonstration that helps you find an inpaint tool and how to use it with ease in a simple way.  

Inpaint tool in Stable Diffusion

  1. Begin by loading Stable Diffusion WebUI on your browser, navigate to the img2img tab, and click on it.
img2img tab
  1. Next, navigate to the Generation tab and click on img2img. Doing so, you’re displayed with the Click to Upload option, and clicking on it lets you choose an image.
img2img - Upload image
  1. After choosing the image, it is added to Stable Diffusion. For demonstration, we added a photo of an apple with two stems and will remove one using the inpaint tool.
Upload an image to img2img
  1. To load the inpaint tool, scroll down to the bottom of the image, and from the options available, click on inpaint.
Click on inpaint next to Copy image
  1. Once done, press S to open the image in full screen. We suggest doing this, as you might have a hard time brushing the image.
Click S after it is uploaded to open it full screen
  1. The brush tool is picked by default, and you can begin by selecting the parts of the image you want to modify. If the brush is too large/small, you can adjust it right away using the slider.
Press S to open image in full screen and select with a brush
  1. After you have selected the desired area, navigate to the top and enter the positive and negative prompts.
Enter the prompt
  1. Next, make changes to options according to your requirements, and while everything isn’t necessary, ensure that you modify the Inpaint area, Width and Height, CFG scale, and Denoising strength, and click on the Generate button.
inpaint tool options
  1. Wait for the image to process, and once done, you will have the image generated with the changes specified in the prompt and selected area.
inpaint - Final result

Wrapping Up

Congratulations on learning how to use the inpaint tool on Stable Diffusion!

Stable Diffusion’s Inpaint tool generates reliable results if you set the right image, prompt, and options. While it could be challenging to get the desired result immediately, be patient, experiment with the possibilities, and get creative with the prompts.

How To Use img2img Stable Diffusion

What Is Clip Skip Stable Diffusion

What Is ControlNet Stable Diffusion

What Is VAE Stable Diffusion

How To Use Stable Diffusion for NSFW


We will be happy to hear your thoughts

Leave a reply

Enable registration in settings - general