Welcome to the HTML Basics section for beginners! If you're new to HTML or looking to refresh your knowledge, this guide will help you get started with the fundamentals of HTML.

What is HTML?

HTML, which stands for HyperText Markup Language, is the standard markup language for creating web pages and web applications. It describes the structure of a web document, and it's the backbone of every web page you visit.

Basic HTML Structure

Every HTML document starts with a basic structure. Here's an example:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>HTML Basics</title>
</head>
<body>
    <h1>Welcome to HTML</h1>
    <p>This is a paragraph.</p>
    <a href="/course-center/languages/en/curriculum/beginners/css-basics">Learn CSS Basics</a>
</body>
</html>

Elements

HTML elements are the building blocks of HTML pages. Here are some basic elements:

  • <html>: The root element that encloses all the content of an HTML document.
  • <head>: Contains meta-information about the document, such as the title and links to CSS and JavaScript files.
  • <body>: Contains the content of the document, such as text, images, links, and other elements.
  • <h1> to <h6>: Used to define HTML headings.
  • <p>: Defines a paragraph.
  • <a>: Defines a hyperlink.

Attributes

Attributes provide additional information about an element. For example, the href attribute of the <a> element specifies the URL of the link.

Images in HTML

To add an image to an HTML document, use the <img> element. Here's an example:

<img src="https://cloud-image.ullrai.com/q/Golden_Retriever/" alt="Golden Retriever">

This will insert an image of a Golden Retriever into your HTML document.

Further Reading

To learn more about HTML, check out the following resources:

Continue to CSS Basics