Scroll to top
Read Time: 18 min

Learn to create a stylized Rubik's Cube in Illustrator. I'll take you through how to make every detail of the final illustration, which will teach you some new techniques and introduce you to some new Illustrator tools. Let's get started with creating this iconic, retro puzzle cube.


Step 1 - Set Up the Document

Create a new document and put in the details below.

Step 2 - Draw a Square

Rename "Layer 1" to "Cube," by double-clicking the layers name in the layers panel.

Press "M" to bring up the Rectangle Tool and then click once inside the document to bring up the Rectangle window, then enter 360px for the width and height and press OK. Give the square a red fill and no stroke.

Step 3 - Turn the Square into a Cube

Press V to bring up the Selection arrow and select your new square. Now go to Effect > 3D > Extrude and Bevel. Put in the dimensions shown below and click OK. Finally, Expand Appearance (Object > Expand Appearance), then lock the "Cube" layer.

Step 4 - Draw a Grid

Create a New Layer (Command + L) at the top of the Layers window and call it "Face1."

Get the Rectangle Grid Tool, which can be selected if you hold down the button for the Line Tool. Click once inside the document and put in the dimensions below, then click OK. Give the grid a dark blue stroke (or any color that's easy to see). Position the grid roughly over the main front face.

Step 5 - Skew The Grid

Enter Preview view by pressing Command + Y.

Press V and select the grid, and then press E to get the Free Transform Tool. On the top right corner of the grid click and hold the small white box that you use to transform an object's shape. Drag the corner inwards very slightly and then press and hold Command straight away. This will let you free-skew the box.

Step 6 - Line the Grid to the Face

Move all the corners so that the grid lines up with the main front face of the cube. This is a bit fiddly as nodes you've already moved will get moved out of place as you transform their opposite corner. You just have to go back over them until the grid lines up exactly to the face of the cube below. Zoom in and out (Command and + or -) to make sure the corners are lined up properly. Lock the layer "Face1" after you've finished.

Step 7 - Do the Same for the Other Faces

Repeat this process for the other two sides on their own layers naming the left side "Face2" and the bottom "Face3."

Don't be afraid to spend a bit of time on this. The bottom face is quite hard to get right, but you need all the corners to line up so persevere. I find small movements and gradually working each corner into place makes it easier.

Step 8 - Check that it Looks Right

Exit Preview (Command +Y) and zoom out so you can see the whole cube.

Step 9 - Delete the Vertical Ends

Now hide the layers "Cube," "Face2," and "Face3" by clicking the small eye icon next to the layer names. Unlock the layer "Face1," select the grid with the Selection Tool (V), and ungroup the lines (Command + Shift + G)

Now deselect the grid by clicking anywhere in the artboard and then select and delete the left and right vertical lines.

Step 10 - Copy the Middle Horizontal Lines

Select the two middle horizontal lines, then press Command + C to copy them and then press Command + F to paste them in front. Turn off the visibility of the lines you just pasted in the layers panel.

Step 11 - Join Up the Ends

Use the Direct Selection Tool (A) to select the two very end nodes on the first and second horizontal lines (when you hover over the end of the line a small white square pops up next to the Direct Selection Tool to show you're over the end of the node).

With these selected, click Command + J or go to Object > Path > Join to join up the ends of the two separate lines. Do this to the other end of the same lines to complete the shape. Then do this for the third and forth horizontal lines underneath.

Step 12 - Join the Middle Lines

After this, make the two lines we copied from the middle visible again and then join up the ends, as you've just done with the others. You might want to move them to the top of the layer to make them easier to click. You should now have something that looks exactly like the grid we started with.

Step 13 - Move the Vertical Ends

Again with the Direct Select Tool (A), select the top node of the second vertical line and press the Up Arrow key once. Then select the bottom node of the same line and press the Down Arrow key once. Do the same for the third vertical line.

See the image below to make sure you are moving the correct nodes.

Step 14 - Divide Below

Select the second vertical line with the Selection Tool (V), move it to the top of the layer (Command + Shift + Right Bracket key) and then go to Object > Path > Divide Objects Below. Do the same with the third vertical line.

You should now have a grid that looks identical to the grid we started with, however now the nine inner boxes should all be individually selectable.

Step 15 - Do the Same for the Other Sides

Lock the layer "Face1", turn it's visibility off and then add grids to layers "Face2" and "Face3." This process started at Step 9 if you want to look back at what we just did.

Tip: As the bottom side is at a very tight angle, when you move its two central vertical lines up by 1 pixel by pressing the up arrow once, you will also need to press the right arrow twice as well to maintain the perspective. Also, when you move the bottom nodes of the lines down, press left twice. The aim is to get the lines to match up on all three faces so keep an eye on the other two sides by turning their visibility on and off as you work.

Step 16 - Prepare to Edit

OK, that was the most fiddly part of this tutorial, but necessary to give us the ability to maintain the cool perspective and edit the inner squares independently of each other.

You can delete the layer "Cube" now. Turn the visibility of the remaining thee layers on, but lock "Face2" and "Face3," and unlock "Face1."

Step 17 - Offset the Path

Now with the Selection Tool (V) select all of the squares in "Face1." With them still all selected go to Object > Path > Offset Path. In the window that pops up enter -4px and click OK.

Step 18 - Round the Corners

Now select all the new inner boxes with the Selection Tool (V) and then group them (Command + G or Object > Group).

Then Select all of the outer boxes and group them. A quick way to do this is to select everything in the layer (Command + A) and then Shift-click the inner boxes, that you just grouped, which will deselect them leaving you with just the outer boxes selected).

Select both the groups and go to Effect > Stylize > Rounded Corners. In the pop up window enter 6px and click OK

Step 19 - Expand the Front Face

With both groups still selected go to Object > Expand Appearance. Then swap their strokes to fills by pressing Shift + X. Change the fill color of the outer boxes to black #000000. Change the fill color of the inner boxes to this blue #0AAEEF for now. You should have the image below.

Step 20 - Add the Black Boxes Together

Use the Selection Tool (V) to select the black boxes, ungroup them (Command + Shift + G), but keep them selected and then click the Add to Shape Area button in the Pathfinder window to make them all into 1 object and then click Expand (If you can't see the Pathfinder window press Command + Shift + F9 or just go to Window > Pathfinder).

Use the Direct Selection Tool (A) to delete the four gaps that are left in the middle between the black boxes by clicking one of the nodes of the gaps and pressing Delete twice.

Rename the new black object inside the "Face1" layer to "Face1Back." Turn the visibility of "Face1Back" off.

Step 21 - Add the Blue Boxes Together

Use the Selection Tool (V) to select the blue boxes. Ungroup them but keep them all selected, and then click the Add to Shape Area button in the pathfinder panel again, then click Expand. Now rename them to "Face1color."

Step 22 - Copy and Paste the Blue Boxes

Copy this set of blue boxes (Command + C) and then turn their visibility off. Paste two copies in the same place and in front of one another by pressing Command + F twice.

Step 23 - Make the Shadow

Select just the top set of squares you just pasted with the Selection Tool (V, and then with the arrows on your keyboard press up three times, and then right three times. Now select both of the two shapes and press the Subtract from Shape Area button in the Pathfinder window, and then click the Expand button.

Step 24 - Have a Look

Change the color of the remaining shapes to this darker blue #099AD4 and rename the object to "Face1Shadow." Now turn the visibility of the "Face1Back" and "Face1color" back on, and lock the layer "Face1."

Step 25 - Do it All Again!

The process for the next two sides use exactly the same techniques, but have small differences so I'll go through them though in less detail.

Unlock and turn the visibility of "Face2" on. Select all the boxes then offset their paths by -3px this time. Group the inner boxes. Group the outer boxes. With them both selected apply a Rounded Corners effect of 6px and then go to Object > Expand Appearance. Swap the strokes to fills.

Select the outer boxes group, ungroup them and then click the Add to Shape Area button in the Pathfinder. Rename the object to "Face2Back," change its color to black #000000, and delete the four gaps between the boxes. Hide the visibility of "Face2Back."

Select the inner boxes group, ungroup them and then click the Add to Shape Area button in Pathfinder and Expand. Rename the selection to "Face2color" change its color to this red #F70D0D. Copy "Face2color" and then hide its visibility.

Paste the two copies on top of each other in the same place. Select the top copy and this time press up two times and then left three times. Select both of the copies and press the Subtract from Shape Area button in the Pathfinder window and click Expand. Change the color of the remaining shapes to this darker red #D40404 and rename the selection to "Face2Shadow." Turn the visibility of "Face2color" and "Face2Back" back on.

Now lock the layer "Face2."

Step 26 - Same Again with Some Small Changes

Finally, for the bottom use the same process again but with a couple of small changes.

Only Offset the Path for the inner boxes by -2px.

This time only select the outer boxes and apply a 6px Rounded Corners effect. Then select the inner boxes and apply the Rounded Corners effect but with 4px instead.

Give the inner boxes this yellow #EDD70C. To make the shadow for the bottom face press down three times, then left one time, and then subtract the shapes from each other. Finally give the shadows this yellow color #CFBB0A.

Step 27 - Copy the Black Shapes

Things should start to be looking more like a Rubik's Cube now, but we need to give it a bit of bulk!

Unlock the three layers called "Face1," "Face2," and "Face3." Now use the Selection Tool (V) to select just the black shapes from each of the layers, which should be called "Face1Back," "Face2Back," and "Face3Back." Copy these three selections (Command + C) and then lock all three layers.

Step 28 - Paste into a New Layer

Create a brand new layer (Command + L) on top of all the others and call it "Outline." Paste in Front (Command + F) the three black shape copies you just made into this new layer. Make sure the three shapes are selected and add a black stroke of 1px in weight aligned to the outside. To align a stroke to the outside of a shape, click the Align Stroke to Outside button in the Stroke panel.

Step 29 - Add Together

Now with the three shapes still selected, go to Object > Expand Appearance, then ungroup them by clicking Command + Shift + G. Finally, click the Add to Shape Area button in the Pathfinder window, then Expand. On the black shape that is left, get your Direct Selection tool (A), and delete the gaps that are left in the middle.

Step 30 - Add the First Stroke

Now select your new shape and bring up the Appearance panel (Window > Appearance). In the panel drag the box that says "Stroke" underneath the box that says "Fill." The fill should already be set to Black ,so select the Stroke box in the Appearance Panel, and add a 4px White #FFFFFF stroke to the shape, as you would do normally.

Step 31 - Add the Second Stroke

With the shape still selected, go back to the Appearance panel and click the small arrow on the right hand side that will bring out a little submenu, then select the option Add New Stroke. You should now be able to see two different strokes in the Appearance panel. Select the bottom one and add a 10px Black #000000 stroke to the shape.

Drag the layer "Outline" to the bottom of the layers panel and lock it.

Step 32 - Add a Gradient to Face1

Let's give the faces a nice glossy feel now. Unlock the layer "Face1" and select the blue boxes, which should be called "Face1color." Now click the Gradient fill button at the bottom of your tools panel and place these settings into the Gradient window (Command + F9): #0CB0F0 at 0%, #29CAFE at 48%, #0AAEEF at 50%, #27C8FD at 76%, #0EB1F1 at 77% and #2CCDFF at 100%. Then set the Angel at 310 degrees. Now lock layer "Face1."

Step 33 - Add a Gradient to Face2

Unlock "Face2" and put in these settings for the gradient effect: #F50D0D at 0%, #F70D0D at 48%, #E41010 at 50%, and #E21010 at 100%. Then set the Angel at 310 degrees. Now lock the layer "Face2."

Step 34 - Add a Gradient to Face3

Unlock "Face3" and put in these settings for the gradient effect: #EDD70C at 0%, and #FFE108 at 100%. Then set the Angel to 15 degrees.

Step 35 - Scale Down

Unlock all four layers now and press Command + A to select everything. Then go to Object > Transform > Scale and put in the dimensions below. Then lock the layers again, as we're finished with them for now. I find it's easier to work bigger sometimes as you can zoom in and be more precise, and then scale it down later. Good old vectors!

Step 36 - Give it a Background

Let's make the background now. Create a new layer at the very bottom of the layers window and call it "Background." Press M to bring up the Rectangle Tool, click once inside the document and and put in 2000px for the width and height. Center the new square behind you Rubik's Cube and give it this color #7DD6EA. With it still selected press Command + 2 to lock the selection within the layer.

Step 37 - Draw a Circle

Now press L to bring up the Ellipse Tool, and draw a circle 480px by 480px. Give the circle a white #FFFFFF fill.

Step 38 - Distort the Circle

Position the circle behind the Rubik's Cube, and with it still selected go to Effect > Distort & Transform, and then enter the dimensions below. Now lock the "Background" layer.

Step 39 - Draw the Top of a Flag

Create a new layer at the top of the layers window and call it "Flag." Press N to bring up the Pencil Tool and draw a line roughly like the one below. Give it a 2px black #000000 stroke and position it so the left end starts just over the left hand side of the Rubik's cube.

Step 40 - Copy, Move and Paste

Copy the stroke (Command + C) and paste a new one in front (Command + F). Then press Shift + Down Arrow key three times to move the copy 30px down.

Copy the line you just moved and paste another one directly in front of it and press Shift + Down Arrow key another three times. Turn the visibility of the middle line off for now.

Step 41 - Join the Top and Bottom Lines Together

Bring up the Direct Select Tool (A) and join up (Command + J) the end nodes on the two lines you can still see. Give the shape a white fill #FFFFFF and call it "FlagFace."

Step 42 - Add a Node

With the shape "FlagFace" still selected bring up the Pen Tool by pressing P and on the right hand side. In the middle of the vertical line add a new node by clicking the line once.

Step 43 - Make Some Tails

Select this node with the Direct Selection Tool (A) and move it inwards so the flag looks like it has a couple of tails. Still with the Direct Selection Tool, grab the bottom left node of the flag and move it right about 3px.

Step 44 - Write on the Flag

Now make that middle line, that we hid a minute ago, visible again. Move it to the top of the layer.

Select the Type on a Path Tool, which can be found if you hold down the Type Tool, and click somewhere towards the left of the line. Now type "Rubik's Cubes Rock!!!". I've chosen Rockwell Bold at 32px as my font, but if you don't have that then try another font out. I find something with block serifs works well though.

Step 45 - Center the Type

With the type still selected go to Type > Type on a Path > Type on a Path Options. Put in the dimensions below to center the type vertical on the path.

If you want to move the type along the path from left to right, and vice versa, then select the type, get the Direct Selection tool, and hover over the beginning of the first word where you should see a vertical line with a white box next to it. When you hover over the box, the Direct Selection Tool will turn black with a small arrow pointing right. When you see this you can click and drag the text either way along the path.

Step 46 - Copy the Flag

Select the flag you've just drawn and copy it. Then press Command + B to paste it behind, then press Shift + Down Arrow key once to move it down by 10px. Change its color to black #000000 with no stroke. Call the shape "FlagShadow."

Step 47 - Copy the Outline

Unlock the layer "Outline" and copy the shape into there, then lock the layer again. Paste the outline shape you've just copied in position at the bottom of the layer by pressing Command + B into the layer "Flag."

Step 48 - Copy the Outline

Select both the pasted outline shape and the shape called "FlagShadow" and press the Intersect Shape Area button in the Pathfinder window followed by Expand. Name the remaining shape "FlagShadow" again and give it a black fill. Change the Opacity to 40% and Lock the layer "Flag."

Step 49 - Draw the Rest of the Flag

Finally create a new layer, just above the layer called "Background," and call it "FlagBack." Press L and draw a quite flat ellipse with the same dimensions shown below.

Step 50 - Position the Curl

Position the shape behind the left hand corner of the flag you drew and give it a 2px black stroke and a light grey (#E8EAEA) fill color. The final image is shown below.

Subscribe to the Vectortuts+ RSS Feed to stay up to date with the latest vector tutorials and articles.

Advertisement
Did you find this post useful?
Want a weekly email summary?
Subscribe below and we’ll send you a weekly email summary of all new Design & Illustration tutorials. Never miss out on learning about the next big thing.
One subscription. Unlimited Downloads.
Get unlimited downloads