How good are LLMs at Rubik's cubes?
RubiksBench shows a model a scrambled cube and asks it for the moves that solve it. This page is the short version. The full write-up, with replays and quotes from the models' thinking, is on my blog: I tested 39 LLMs on solving Rubik's cubes with no tools
A Rubik's cube has a short notation for its 18 moves. Six faces (Up, Down, Left, Right, Front, Back), each turned clockwise, anticlockwise or halfway round. No mark is clockwise, as you look at that face. An apostrophe is anticlockwise. A 2 is a half turn.
| Face | Clockwise | Anticlockwise | Half turn |
|---|---|---|---|
| Up | U | U' | U2 |
| Down | D | D' | D2 |
| Left | L | L' | L2 |
| Right | R | R' | R2 |
| Front | F | F' | F2 |
| Back | B | B' | B2 |
The whole cube can also be written in 2D, unfolded into a cross with each sticker as a letter. So you have a text input (the cube) and a text output (a list of moves), which makes it a good test for an LLM.
Show a model a scrambled cube and ask it to reply with the moves that solve it. That's it. A few rules:
- No tools. Ask claude.ai or chatgpt.com and you'll get the right answer almost every time, because they write a script that calls a solver library. So each cube is one request through OpenRouter, with no tools, and I score whatever comes back.
- One reply. No feedback and no second try. Temperature is 0 on every call.
- Same cubes for every model, in the same order.
- Scrambles go 3, 6, 10 and 20 moves. A model has to solve at least one cube to move up a length. 3 moves is a sanity check, not a score: a model gets up to 5 cubes and one solve is a pass. 6, 10 and 20 moves get 10 cubes each.
- Reasoning models only. I tried non-reasoning models early on. They all failed, so I dropped them.
- Default thinking level first. Then higher or lower, depending on how the model failed.
My code plays the moves on the cube. A cube counts as solved only when all 54 stickers are back in place. The full prompt is under Method on the leaderboard, and every model page shows the prompt, the answer, the thinking and a replay for each cube.
Every one of the 43 quintillion positions of a 3x3 cube can be solved in 20 moves or fewer. This is known as God's number. So a cube scrambled with 50 or 100 moves is no harder than one scrambled with 20. I checked this on an early version of the prompt: scores at 25, 50 and 100 moves sat in the same range as at 20.
On 3-move scrambles, the models that pass just play the scramble backwards. From 6 moves up, they solve the cube the way a beginner learns: one layer at a time, with small, fixed move sequences. It's not sexy, but it works. Each sequence fixes a piece or two without breaking the ones already solved.
So the answers that work are long, often over 100 moves for a cube that needs 20 at most. Short answers are usually a model going for the shortest route and missing.
Mostly in one of three ways:
- Wrong answer. A legal list of moves that doesn't solve the cube.
- Refusal. Something like "I cannot solve this cube without computational tools".
- Thinking itself to death. The model spends its whole token budget thinking and never writes an answer.
The rest are rare: the right moves with junk stuck on the end, or a provider that cuts every call off after a few minutes.
The thinking setting decides how much of the token budget goes on thinking and how much is left for the answer. At max, a model might get 95% of its budget for thinking. If it uses all of it, nothing is written and the cube is a fail.
The Anthropic models tend to do better at a lower setting, because it forces them to stop and commit. The OpenAI models nearly always stop and answer, so more thinking helps them. A lower setting doesn't make a weak model good, though. It turns a fake zero into a real one: only a zero with written answers tells you the model can't do the task.
Providers don't return the same answer every time, even at temperature 0. One model solved 0 of 10 cubes, then 2 of the same 10 on a second run. So read any score out of 10 as give or take 2.