Static and Dynamic Web PagesOptional for Computer Science
🎬 This chapter has a 12:38 video: Web Services →Your school’s “About us” page looks the same to you, to your friend, and to a stranger in another city. Your exam result page does not. Both are web pages, and the difference is where the page is put together.
1A static web page
Nothing is worked out while you wait. The page was written once and put on the server, and it stays exactly that until somebody replaces it.
2A dynamic web page
Switch the visitor. On a static page nothing changes; on a dynamic page the server builds a different page each time.
about.html <h1>About our school</h1> <p>Founded in 1985 …</p>
One finished HTML file, written once. The server just hands it over, unchanged.
Founded in 1985, Sunrise School has 1,200 students.
Switch between Riya and Arjun: the page does not change at all. It is the same file for everyone, and it stays that way until somebody edits it.
A printed menu and a cooked meal
3Side by side
| Static web page | Dynamic web page | |
|---|---|---|
| Built | Once, by hand | Every time it is requested |
| Same for everyone? | Yes | No — it can differ per visitor |
| Server runs a program? | No, it just sends the file | Yes |
| Database? | Not used | Usually used |
| Speed | Faster to load | Slower — there is work to do first |
| Changing the content | Edit the HTML file | Change the data, the page follows |
| Example | A school's About us page | Exam results, a booking page, a news feed |
4From the board papers
▶Show the answer
A dynamic web page. Each donor enters their own details and amount, the server has to record them in a database and build a receipt for that donor, so the page cannot be the same finished file for everyone.
▶Show the answer
A dynamic website. Every student must see their own result, so the server has to look each student up in a database after they log in and build a page for that one student.
(A) Its content updates very frequently.
(B) It displays different content to different users.
(C) It loads slower than a dynamic web page.
(D) It shows the same content unless the code is manually updated.CBSE board exam 2026
▶Show the answer
(D). A static page is a stored file, so it keeps showing the same thing until a person edits it. (A) and (B) describe a dynamic page, and (C) is the wrong way round — static pages load faster.
▶Show the answer
(B) Dynamic web pages. Prices and weather come from data that keeps changing, so the page has to be built again each time it is asked for.
What a web page and a website are, if you need it first, is on the Website and Web Page page.
5Check yourself
A page shows a spinning logo and a photo slideshow. Every visitor sees exactly the same thing. Is it static or dynamic?
Which of these almost always needs a database on the server?