Water Jug — free online puzzle game
2-10 min
Water Jug

Water Jug

Puzzle

Measure an exact amount of water with jugs that have no markings. Fill from the tap, empty down the drain, pour one jug into another, and hit the goal in as few moves as you can.

Score 0 Best 0

Home / Puzzle / Water Jug

Water Jug is a free online version of the classic water pouring puzzle. The jugs have no markings, so every move is all or nothing: fill a jug to the brim from the tap, empty it down the drain, or pour it into another jug until the first is empty or the second is full. Use those three moves to measure an exact amount, such as four litres with a 3-litre and a 5-litre jug. Later levels add a third jug, ask for the water in one particular jug or two amounts at once, and take away the tap and the drain altogether so a full jug of milk, cider or oil has to be shared into equal halves without a drop wasted. A computer search sets par for all twelve levels, so three stars are always possible, and the Hint button names the next move from wherever you are. Not to be confused with colour-sorting water games — here the puzzle is the arithmetic. No download, no sign-up, works on phones.

How to play Water Jug

  1. Each level shows some jugs, the litres each one holds, and a goal — for example exactly 4 litres in any jug. A red dashed line marks the amount on the jugs it applies to.
  2. Tap a jug to pick it up, then tap where its water should go: another jug to pour into, or the drain to empty it. Tap the tap and then a jug to fill that jug to the brim. You can also drag a jug onto another jug or the drain, or drag from the tap onto a jug.
  3. The jugs have no markings, so a pour always runs until the first jug is empty or the second is full, whichever comes first. You cannot pour "about half".
  4. Some levels have no tap and no drain. Then all the water you will ever have is already in the jugs, and the goal is to share it out exactly.
  5. Every fill, empty or pour counts as one move. Reach the goal in par — the fewest moves possible — for three stars; within the two-star line for two; any finish earns one.
  6. Undo takes back the last move and Start Again resets the level. Hint names the next move on a shortest route from wherever you are.
  7. On a keyboard, number keys pick jugs, T is the tap, D is the drain, U undoes, H gives a hint and Esc lets go of a picked jug.

Tips

  • Count what a pour leaves behind, not what it moves. Filling the 5 and pouring it into the 3 leaves exactly 2 in the 5 — that remainder is usually the step you need.
  • With two jugs there are really only two ways round: keep refilling the small jug and pouring it into the big one, or keep refilling the big one and pouring it into the small one. Try both; one is usually much shorter.
  • Emptying the jug you just filled, or pouring straight back what you just poured, wastes two moves. If you catch yourself doing it, use Undo instead.
  • In a sharing level the total never changes. Work out which amounts each jug can hold on the way and aim for a half in the jug that can take it.
  • If the goal is two amounts at once, make the harder one first and park it in a jug you will not need to touch again.

FAQ

Is Water Jug free to play?

Yes. It runs in the browser with no download, no sign-up and nothing to buy. All twelve levels are included and unlock one after another as you finish them.

How do you get exactly 4 litres with a 3-litre and a 5-litre jug?

Fill the 5 and pour it into the 3, which leaves 2 in the 5. Empty the 3 and pour the 2 into it. Fill the 5 again and top up the 3, which takes just 1 litre. Exactly 4 litres are left in the 5. That is six moves, and no shorter way exists.

Is this the puzzle from Die Hard with a Vengeance?

The same puzzle appears in that 1995 film, with a 3-gallon and a 5-gallon jug and exactly 4 gallons to measure. Here it is level 3, in litres. The puzzle itself is far older than the film.

Which amounts can two jugs measure?

With a tap and a drain, two jugs can measure exactly the amounts that are multiples of the largest number dividing both sizes, up to the size of the bigger jug. A 3 and a 5 can make every amount from 1 to 5 litres; a 4 and a 6 can only ever make even amounts, so 3 litres is impossible with them.

How do you share 8 litres into two 4s with a 5 and a 3?

It takes seven pours: 8 into 5, 5 into 3, 3 into 8, 5 into 3, 8 into 5, 5 into 3, and 3 into 8. That leaves 4 litres in the big jug and 4 in the 5-litre jug. It is level 5, Share the Milk.

How are par and the stars worked out?

A computer search tries every position a level can reach and finds the fewest moves to the goal, so three stars are always possible. The two-star line is the median of 41 runs by a careful trial-and-error player that never pours straight back what it just poured and spots a finish three moves away. Any finish earns one star.

Can I get stuck?

No. On every level the goal can still be reached from any position you can get to, even in the sharing levels where a pour cannot always be poured back, so Hint always has a next move for you. Undo and Start Again are there if you would rather go back.

Does Water Jug work on a phone?

Yes. Tap a jug and then where its water should go, or drag it there with a finger. On a phone held upright the jugs sit above the goal and the buttons; on a wider screen the goal sits beside them.