Understand what is meant by a uniform resource locator (URL)

The Internet and Its Uses

Objective

Students will be able to understand what is meant by a Uniform Resource Locator (URL), describe its components, and explain how a web browser uses a URL to retrieve resources from the World‑Wide Web.


1. Internet vs. World‑Wide Web

  • Internet: The global network of hardware (cables, routers, servers, etc.) that connects computers worldwide.
  • World‑Wide Web (WWW): A collection of web pages and other resources that are accessed over the Internet using the HTTP/HTTPS protocols.

2. What Is a URL?

A Uniform Resource Locator (URL) is the address that uniquely identifies a resource—such as a web page, image, video, or API endpoint—on the Web. When you type a URL into a browser, the browser uses it to request the resource from the appropriate server and then displays the returned data.

3. Key Components of a URL

Component Description
Protocol Method used to retrieve the resource (e.g., http, https, ftp).
Domain name Registered name of the server that hosts the resource (e.g., example.com). The www. prefix is optional.
Port (optional) Numeric identifier for the specific service on the server. Default ports: 80 for HTTP, 443 for HTTPS. A non‑default port follows a colon, e.g. :8080.
Path Location of the file or resource within the server’s directory structure, beginning with a forward slash (e.g. /folder/page.html).
Query string (optional) Additional parameters sent to the server. Begins with ? and uses & to separate key‑value pairs (e.g. ?id=10&sort=asc).
Fragment identifier (optional) Points to a specific part of the resource, such as a heading within a page. Begins with # (e.g. #section2).

4. Example URL Breakdown

https://www.example.com:8080/articles/technology.html?id=42&lang=en#introduction

  • Protocol: https
  • Domain name: www.example.com
  • Port: 8080
  • Path: /articles/technology.html
  • Query string: id=42&lang=en
  • Fragment identifier: #introduction

5. Conversion Exercise (Practice Extracting Parts)

Identify the six components of the following URL:

http://blog.school.edu:8080/resources/lesson.pdf?year=2025&type=pdf#page3

  • Protocol = __________
  • Domain name = __________
  • Port = __________ (if any)
  • Path = __________
  • Query string = __________
  • Fragment identifier = __________

6. How a Browser Uses a URL

When a URL is entered, the browser follows these steps (summarised for IGCSE level):

  1. Parse the URL – separate protocol, domain, port, path, query and fragment.
  2. DNS lookup – translate the domain name into an IP address.
  3. Open a TCP connection to the server on the appropriate port (80 for HTTP, 443 for HTTPS).
  4. Send an HTTP/HTTPS request (usually GET) that includes the path and any query string.
  5. Web server processes the request and returns an HTTP response containing a status code, headers, and the requested resource.
  6. Browser renders the resource – parses HTML, applies CSS, runs JavaScript, and displays the page.
  7. If a fragment identifier is present, the browser scrolls to that part of the page after rendering.
Suggested diagram: Flow of a URL request – browser → DNS lookup → server → HTTP/HTTPS response → rendering.

7. Role of a Web Server

A web server is software (e.g., Apache, Nginx) running on a computer that:

  • Listens for incoming HTTP/HTTPS requests on a specific port.
  • Interprets the request line and headers.
  • Generates an HTTP response that includes a status code (e.g., 200 OK, 404 Not Found), response headers, and the requested content.
  • Optionally sends cookies back to the browser.

8. HTTP vs. HTTPS – Quick Comparison

Protocol Default Port Encryption? Typical Use
http 80 No – data is sent in plain text Public information, non‑sensitive sites
https 443 Yes – TLS/SSL encrypts the data Login pages, e‑commerce, any personal data

9. Cookies (Brief Overview)

Web servers can send small pieces of data called cookies to a browser. Cookies are stored on the user’s device and automatically sent back with subsequent requests to the same domain.

  • Session cookies – deleted when the browser is closed; used for temporary tasks such as keeping a shopping‑cart active during a visit.
  • Persistent cookies – have an expiry date; used for remembering login details, language preferences, or items added to a wishlist.

Real‑world example: When you add items to an online store’s basket, a session cookie stores the IDs of those items so the basket remains intact as you move between pages.

10. Security Tip

URLs can be spoofed in phishing attacks (e.g., http://paypa1.com mimics paypal.com). Always verify that:

  • The protocol is https for any site that asks for personal or payment information.
  • The domain name is spelled correctly and matches the expected organisation.

11. Why URLs Are Important

  1. Provide a unique address for every resource on the Web.
  2. Allow browsers to send HTTP/HTTPS requests to the correct server.
  3. Enable search engines to index and retrieve pages.
  4. Can be shared, bookmarked, and embedded in documents or applications.

12. Common Everyday Uses of URLs

  • Opening web pages in a browser.
  • Linking to files stored on cloud services (Google Drive, OneDrive, etc.).
  • Embedding videos or images in social‑media posts.
  • Calling APIs to exchange data between applications.
  • Downloading software updates or digital documents.

13. Quick Quiz

  1. Which part of a URL tells the browser which protocol to use?
  2. Identify the domain name in the URL http://blog.school.edu/articles?id=5.
  3. Explain the purpose of a query string.
  4. When might you use a fragment identifier?

14. Further Reading & Cross‑References

  • “Web Browsers, HTTP/HTTPS and Cookies” – detailed look at request/response cycles and cookie handling.
  • “Network Hardware & Data Transmission” – introduces routers, switches and the role of IP addresses.
  • “Cyber Security Basics” – covers phishing, secure URLs and the importance of HTTPS.
  • Cambridge IGCSE Computer Science syllabus – Unit 5.1 (Internet and the World‑Wide Web).

Create an account or Login to take a Quiz

38 views
0 improvement suggestions

Log in to suggest improvements to this note.