Sketch Tutorial: How to create Donut Charts

Rachit
Designer Recipes
Published in
2 min readDec 7, 2015

--

by Rachit Gupta

I use Sketch for almost all of my design work. A few days back someone asked me how to create donut charts in Sketch and I realized that it isn’t as easy as it might appear to be. Here’s a quick and simple trick to create donut charts in Sketch:

TL;DR: ‘Subtract’ two ovals to form the outline of the donut and ‘Mask’ it with a rectangle of appropriate size.

Step 1: Create an oval of desired size

Hit ‘o’ on your keyboard and start dragging to create an oval. Set a symmetrical desired size.

Step 2: Duplicate the oval into another of small size and subtract the two

Create the donut by create another small oval and subtracting both of them:

Step 3: Create a rectangle and Mask it with the donut

Finally, create a rectangle of appropriate size, fill it with a color and mask it with the donut resulting from step 2:

Notice when I kept the donut layer above the rectangle layer, Sketch treats rectangle as a mask. We don’t want that. Instead, we want the donut layer to be treated as a mask so be sure to place the rectangle on top.

Step 4: That’s it! Play around with the visuals

And that’s it! Neat and easy. You can play around with the rectangle shape and change how it affects the donut chart.

Pie charts can be created easily using similar tricks. Try it out and let me know if you did it! :-)

--

--