Safekipedia

Web page

Discoverer · ages 10+Adapted from Wikipedia
A screenshot of the Wikipedia article about the platypus, shown in the Vector 2022 website design.

A web page, or webpage, is sometimes called just a page. It is a document that is usually published on the Web and normally viewed using a web browser.

Each article on the Wikipedia website is a distinct web page. The page's unique URL is visible in the web browser's address bar at the top.

A web page is made of hypertext and often other parts, such as scripts and graphics.

An author may publish one or more related web pages together in a website. Because of this, the words website and web page work like a metaphor for paper pages bound together into a book.

Main article: Web navigation

Each webpage has a unique web address, called a URL, that helps people and programs find it. When a program is given a URL, it sends an HTTP request to the web server that holds the page. Usually the program takes the domain name from the URL and does a DNS lookup to find the server, but sometimes the URL gives the IP address of the server directly. The server sends back a copy of the page, written as hypertext. Some programs, such as wget, simply save this copy. A web browser reads the hypertext and shows the page as something people can see and interact with. The hypertext may also point to extra files, like scripts or pictures, which the browser gets too.

A page may have one or more hyperlinks that can be clicked or tapped to go to another page, either on the same website or a different one. A URL can be typed into a browser's address bar, or opened automatically through a saved bookmark or shortcut, such as a link in an email. Web pages can also be saved to a device and opened later from a file path instead of a web address, though some interactive features may not work and some files may be missing.

Elements

A web page is basically a structured document made of text written in HyperText Markup Language (HTML). This usually includes all of the page's text that stays the same, although some websites load some of this text using JavaScript.

The page may also point to other files, either on the same website or on another one, and some of these files may be placed directly inside the page. These include Cascading Style Sheets (CSS), which give presentation rules that tell a browser how the page should look. They also include JavaScript, which allows a wide range of behavior, such as more interaction and loading extra content. The vast majority of web pages reportedly use JavaScript. WebAssembly helps JavaScript do complex work more efficiently and lets code written in other programming languages be reused. Pictures such as icons, logos, and images in various formats, including SVG, are also part of many pages. The most advanced pages, called web apps, combine these elements in a complex manner.

Deployment

From the point of view of server-side website deployment, web pages come in two types: static and dynamic. Static pages are simply taken from the web server's file system and a copy is sent to the visitor without any changes. Dynamic pages are created by the server on the fly, just before they are sent.

Dynamic pages often get information from a database and place it into the text, and they may change how content looks or what is included based on URL parameters. They also often use caching of generated content to work more efficiently. An example of a dynamic page is a search engine results page.

Security and privacy

When the web was first invented, pages were retrieved using plain HTTP. Because this method was simple, third parties could eavesdrop or carry out man-in-the-middle attacks, which threatened people's privacy and security. The HTTPS extension added a layer of encryption that largely eased these concerns. At first, it was typically only adopted by sites such as banks and online shops. Later, HTTPS became much more widely used. Major browsers started automatically making HTTPS requests instead of HTTP for links, warned users when websites still did not support HTTPS, and required users to confirm before going on.

Another modern security feature of websites and web browsers is Content Security Policy, which helps protect against cross-site scripting attacks.

Quiz time!

5 questions about Web page

Question 1 of 5

Besides hypertext, what other parts can a web page have?

Keep exploring

This article is a child-friendly adaptation of the Wikipedia article on Web page, available under CC BY-SA 4.0.

Images from Wikimedia Commons. Tap any image to view credits and license.