DEV Community

Irvirty
Irvirty

Posted on

Instruction: how to create a website (HTML file, webpage, or HTML document)

To create an HTML page and view it, we will use your pre-installed programs, such as a text editor and a browser.

  1. First step: you need to create a file "index.html" with the ".html" extension. To do this, use this instruction to enable file extensions:

Create a file: index.html

  1. The second step is to place this code in an index.html file. To do this, open your index.html file in a text editor or in a code editor, copy this code, paste it into the editor, and save the changes or save file (or save as "index.html").

code:

<!DOCTYPE html>
<html>
<head>
<title>This is a title</title>
</head>
<body>
<p>Hello world!</p>
</body>
</html>

  1. Done. Open your index.html file in a browser, such as Chrome, Firefox, Edge, or Safari, to see the result.

Sources:

Top comments (0)