Open the editor

Computer science · High school

Caesar Cipher Slides

Free animated slides, ready to teach: 6 slides where every step appears on a click and the diagrams move. Play them right here, present them full screen, or copy them into your account to edit.

A real Tracé deck playing in your browser. No account needed.

What the lesson covers

The Caesar cipher shifts every letter of a message by the same number of places. Students encrypt and decrypt with a key, write the rule with mod 26 and see why only 25 keys make it easy to break by brute force or by letter frequencies.

The slides, one by one

1 Encryption and Caesar ciphers

Shift every letter

How did Julius Caesar hide his messages?

2 Shift each letter by the key

C = (P + k) \bmod 26

Key 3: H → K, E → H, L → O

3 Only 25 keys: try them all

Decrypt KHOOR with each key

Key 3 gives a real word

4 Encrypting with numbers

Encrypt HELLO with key 3, using A = 0, B = 1, …, Z = 25.

→ Turn letters into numbers, add 3, take mod 26, turn back

H, E, L, L, O = 7, 4, 11, 11, 14
+3:\ 10, 7, 14, 14, 17
\bmod 26:\ \text{no change}
10, 7, 14, 14, 17 = \text{K, H, O, O, R}

HELLO becomes KHOOR

5 Quick check

Decrypt IBQQZ, which used key 1.

  • HAPPY
  • JCRRA
  • HAPPZ
  • GZOOX
Show the answer

HAPPY

Shift each letter back by 1: I→H, B→A, Q→P, Q→P, Z→Y.

6 What to remember

Encrypt: shift by the key

C = (P + k) \bmod 26
\textsf{Decrypt: shift back by }k

Only 25 keys: easy to break

Challenge: How could letter frequencies (E is the most common) break a Caesar cipher without trying every key?

Every slide is built click by click: text, formulas and pictures come in one step at a time, so the class follows the reasoning instead of reading ahead. Graphs with sliders can be dragged live while you present.

Make your own version with AIChange the level, the numbers or the language: type the topic and get a new deck that moves in about 30 seconds. Free, no account needed.

Questions teachers ask

How does the Caesar cipher work?

Each letter is replaced by the letter k places further along the alphabet, wrapping from Z back to A: with numbers A = 0 … Z = 25, C = (P + k) mod 26. With k = 3, HELLO becomes KHOOR.

Are these slides really free?

Yes. Watch them on this page or present them full screen with no account. Making your own copy to edit is free too.

Can I change the slides before my lesson?

Yes. Press "Make my own copy" and the deck becomes one of your projects in the Tracé editor, where you can change the text, the numbers, the colours or the order of the clicks.

Do they work on a classroom projector or an interactive whiteboard?

Yes. They run in the browser on any laptop, so anything that shows your screen works. Press the right arrow or click to go to the next step.