Home·Cube algorithms

119 Rubik’s cube algorithms

The three CFOP stages in one place: 41 F2L cases, 57 OLL and 21 PLL. Every diagram is drawn by actually running the algorithm on a cube.

Reading the notation

Each letter is a face. Plain means a quarter turn clockwise, an apostrophe means counter-clockwise, a 2 means a half turn.

U · D
Up and down faces
R · L
Right and left faces
F · B
Front and back faces
R'
A quarter turn counter-clockwise
R2
A half turn — direction does not matter
r · Rw
The right two layers together
M
The slice between R and L, following L
E · S
The slices between U and D, and between F and B
x · y · z
Turn the whole cube the way R, U and F go

F2L — first two layers41

Pair a corner with its edge and drop them into the slot. The 41 cases count every position and orientation the pair can take.

OLL — orient the last layer57

Make the top face one colour without disturbing the two layers below. There are exactly 57 cases.

OLL 1
R U2 R2 F R F' U2 R' F R F'
OLL 2
F R U R' U' F' f R U R' U' f'
OLL 3
f R U R' U' f' U' F R U R' U' F'
OLL 4
f R U R' U' f' U F R U R' U' F'
OLL 5
r' U2 R U R' U r
OLL 6
r U2 R' U' R U' r'
OLL 7
r U R' U R U2 r'
OLL 8
r' U' R U' R' U2 r
OLL 9
R U R' U' R' F R2 U R' U' F'
OLL 10
R U R' U R' F R F' R U2 R'
OLL 11
r U R' U R' F R F' R U2 r'
OLL 12
M' R' U' R U' R' U2 R U' R r'
OLL 13
F U R U' R2 F' R U R U' R'
OLL 14
R' F R U R' F' R F U' F'
OLL 15
l' U' l L' U' L U l' U l
OLL 16
r U r' R U R' U' r U' r'
OLL 17
R U R' U R' F R F' U2 R' F R F'
OLL 18
R U2 R2 F R F' U2 M' U R U' r'
OLL 19
M U R U R' U' M' R' F R F'
OLL 20
r U R' U' M2 U R U' R' U' M'
OLL 21
R U2 R' U' R U R' U' R U' R'
OLL 22
R U2 R2 U' R2 U' R2 U2 R
OLL 23
R2 D' R U2 R' D R U2 R
OLL 24
r U R' U' r' F R F'
OLL 25
F' r U R' U' r' F R
OLL 26
R U2 R' U' R U' R'
OLL 27
R U R' U R U2 R'
OLL 28
r U R' U' r' R U R U' R'
OLL 29
R U R' U' R U' R' F' U' F R U R'
OLL 30
F R' F R2 U' R' U' R U R' F2
OLL 31
R' U' F U R U' R' F' R
OLL 32
S R U R' U' R' F R f'
OLL 33
R U R' U' R' F R F'
OLL 34
R U R2 U' R' F R U R U' F'
OLL 35
R U2 R2 F R F' R U2 R'
OLL 36
L' U' L U' L' U L U L F' L' F
OLL 37
F R' F' R U R U' R'
OLL 38
R U R' U R U' R' U' R' F R F'
OLL 39
L F' L' U' L U F U' L'
OLL 40
R' F R U R' U' F' U R
OLL 41
R U R' U R U2 R' F R U R' U' F'
OLL 42
R' U' R U' R' U2 R F R U R' U' F'
OLL 43
F' U' L' U L F
OLL 44
F U R U' R' F'
OLL 45
F R U R' U' F'
OLL 46
R' U' R' F R F' U R
OLL 47
R' U' R' F R F' R' F R F' U R
OLL 48
F R U R' U' R U R' U' F'
OLL 49
r U' r2 U r2 U r2 U' r
OLL 50
r' U r2 U' r2 U' r2 U r'
OLL 51
F U R U' R' U R U' R' F'
OLL 52
R U R' U R U' B U' B' R'
OLL 53
l' U2 L U L' U' L U L' U l
OLL 54
r U2 R' U' R U R' U' R U' r'
OLL 55
R U2 R2 U' R U' R' U2 F R F'
OLL 56
r U r' U R U' R' U R U' R' r U' r'
OLL 57
R U R' U' M' U R U' r'

PLL — permute the last layer21

Used when the colour is done and only the places are wrong. Send the last-layer pieces home and the cube is solved.

How to use this

  • Each diagram looks down on the cube from above. The nine middle squares are the top face; the tabs around them are the first row of each side.
  • A filled square already shows the colour you are aiming for. Find the picture that matches your cube and use that algorithm.
  • If nothing matches, turn the cube a quarter at a time and look again from all four sides. The same case looks different from each angle.
  • Every diagram was drawn by running the algorithm, not by copying a chart: it is what a solved cube looks like after the algorithm is played backwards.

Frequently asked questions

Q. What is CFOP?

It stands for Cross, First Two Layers, Orient Last Layer and Permute Last Layer — the method most competitors use. This page covers the three stages that need algorithms.

Q. Do I have to learn all 119?

No. OLL can be done in two looks with about ten algorithms, and six are enough for PLL. F2L is better understood than memorised. Treat the table as something to look up when you get stuck.

Q. Why does one case have several algorithms elsewhere?

There is more than one way to solve any shape, and which one flows best differs from hand to hand. Only one widely used algorithm is listed per case; if you already know another, keep it.

Q. The picture does not look like my cube.

Turn the cube a quarter at a time and check all four sides — the same case looks different depending on which face you hold in front. Remember to align the top layer first.

Q. Where do the diagrams come from?

Only the algorithms are stored. Playing an algorithm backwards on a solved cube produces exactly the case it solves, and that result is what gets drawn — so a picture cannot disagree with its algorithm.