Build an Animated Water Cycle Diagram for a Science Lesson in HTML

A single HTML page with an animated SVG water cycle that labels evaporation, condensation, precipitation and collection, with step-through buttons and narration notes for teachers.

You getone complete HTML file in a single code block, then 3 short ideas to extend it.

The prompt

Prompt
Act as a front-end developer who builds classroom visuals for science teachers. Build "Rain Round", an animated water cycle diagram for a science lesson. Draw an inline SVG scene: sun, ocean on the left, green mountains on the right, a cloud above the peaks and a river running downhill to the sea. Animate droplets for each stage: vapour dots rising from the ocean into the cloud, dots drifting inward to build the cloud, teardrop rain falling on the slopes, and droplets travelling along the river into the ocean.

Rules:
1. Five steps: Overview, Evaporation, Condensation, Precipitation, Collection. Back and Next buttons, numbered stage chips, an Auto tour toggle that advances every 8 seconds, and a Pause motion button.
2. The active stage keeps its label pill, dashed flowing arrow and droplets at full strength; the other stages dim to about 25 percent opacity.
3. A side panel announced with aria-live shows the stage name, two sentences of narration, an "Ask the class" question and one vocabulary word.
4. Keyboard: Left and Right arrows step, keys 0 to 4 jump, Space pauses. Buttons at least 44px tall with visible focus rings.
5. One readable color per stage, system fonts, layout stacks below 820px; prefers-reduced-motion slows droplets and stops the spinning sun and arrow motion.
6. No external files, images, fonts or storage.

Output format: one complete HTML file in a single code block, then 3 short ideas to extend it.

Example output

One HTML file. Save it and open it in any browser.Open full screen

Example: Rain Round, an animated water cycle for the classroom.

The page opens on an overview with all four stages moving at once: vapour rising from the sea, a cloud gathering droplets, rain on the mountains and a river running home. Press Next or the right arrow to focus one stage; the others dim and the side panel shows narration, an Ask the class question and a key word. Try Auto tour or press Space to pause.

Written by AI from this prompt. Your results will vary.

Tips and common edits

Why this works

  • Naming each droplet path (rise, converge, fall, follow river) gives the model concrete animations instead of a vague 'make it move'.
  • Dimming inactive stages rather than hiding them keeps the whole loop visible while the teacher narrates one step.
  • Fixed stage list, keys and panel fields remove guesswork, so the first output already works as a lesson tool.

Paste into ChatGPT, Claude or Gemini. Save the returned code as water-cycle.html and open it in any browser, or view it in the chat's preview or canvas. Put it on a projector and step through with the arrow keys.

Common edits

  • Swap the narration and questions for your year group, or add a fifth stage for groundwater or transpiration from trees.
  • Change the auto tour timing from 8 seconds, or recolor the stages to match your school slide theme.

Prompt details

By
Prompts-GPT editors
Published

Did this prompt work?

Keep exploring

More in Animations & Effects