HTML, CSS & JavaScript: a beginner's course
HTML, CSS & JavaScript is a short, interactive HTML, CSS and JavaScript course for complete beginners. In 15 sections it shows what each language does: HTML builds the content of a page, CSS styles and lays it out, and JavaScript makes it respond. You write a tag, nest elements, adjust the box model, arrange a layout with flexbox and complete a JavaScript function, with a practice task every few sections.
It is a first step, not a full web development bootcamp. It gives you the core ideas and vocabulary so that longer tutorials, and the Code Editor, make sense.
What the course covers
| Sections | Topic | What you do |
|---|---|---|
| 1 to 3 | HTML elements and tags: headings, paragraphs and links | Write an h2 tag into a ready-made page |
| 4 to 5 | Nesting elements | Drag elements into the right nested order to build a navigation bar |
| 6 to 8 | CSS rules and the box model | Adjust padding, border and margin, with the right CSS units, to match a target |
| 9 to 11 | Layout: flex, block and inline | Pick the CSS property that arranges elements as shown |
| 12 to 15 | JavaScript: what it is for, functions and loops | Put the lines of a function in order so it returns the target text |
HTML: the content
An HTML page is built from elements, each wrapped in an opening tag and a closing tag with a slash. <h1> is the biggest heading, <p> is a paragraph and <a> is a link. Elements go inside each other, which is called nesting, and that structure is what CSS and JavaScript work with later.
CSS: the look and the layout
A CSS rule picks elements with a selector and sets properties such as colour. Every element is a box: content, then padding inside the border, then margin outside it. Block elements take the full width, inline ones only the space they need, and flexbox lines children up in a row or column with control over the spacing.
JavaScript: the behaviour
JavaScript changes the page after it loads: updating text, changing styles and responding to clicks. The course introduces two building blocks, the function, a named group of instructions, and the loop, which repeats instructions.
Try a task from the course
An h2 is a second-level heading, used for section titles under the main h1. It needs an opening tag, the text, and a closing tag with a slash:
<h2>My favourite books</h2>Now add an h2 to a ready-made page, then press Mark to check it in the course.
Practice: create a H2 tag in some pre-made html with a single line text box for the user to code in
Press Mark to have your answer marked in the HTML, CSS & JavaScript course.
Who this course is for
- Complete beginners who have never written code and want to see what web development involves.
- Students starting a computing course who need the basics of HTML and CSS.
- People using AI to build websites who want to understand the code it writes.
What you need to know first
Nothing. You need a browser and the patience to type a few angle brackets carefully. No software has to be installed.
How long it takes
There are 15 short sections. Learners without a plan can open two sections of a course a day, in order, so it takes 8 days that way. A plan removes the daily limit, so you could finish it in one sitting.
Where to go next
Practise in the Code Editor, which has separate HTML, CSS and JavaScript tabs and a live preview. Then the Web Frameworks & Stacks course explains how React, Next.js and Express build on these three languages, and Hosting & Deployment shows how to put a site online.
Common questions
Is this HTML, CSS and JavaScript course free?
Should I learn HTML, CSS or JavaScript first?
What is the difference between HTML, CSS and JavaScript?
Is HTML a programming language?
Can I build a website after this course?
Do I need to install anything?
Revision cards
Say the answer first, then flip the card to check it.
Where to go next
- Solve it
Code Editor
Write and run code right in your browser
Open the tool - Learn it
HTML, CSS & JavaScript
Learn how to think like a web developer from the ground up
Start the course