Best matchWeight Converter
Read form values and use them in the project logic.
Build a weight converter →Build a temperature converter with HTML, CSS, and JavaScript while practicing DOM selection and input values.
Build a temperature converter using HTML, CSS, and JavaScript, then connect the interface to the logic that makes it work. You’ll learn how to convert a value and keep the result easy to understand while getting hands-on practice with DOM selection, input values, and number formatting.
Recommended knowledge: Basic HTML and CSS, JavaScript variables and number operations, DOM selection and form events.
This project runs directly in the browser with HTML, CSS, and JavaScript.
index.html<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Temperature Converter</title>
<link rel="stylesheet" href="style.css" />
</head>
<body>
<div class="container">
<h1 class="heading">Temperature Converter</h1>
<div class="temp-container">
<label for="celsius">Celsius:</label>
<input
onchange="computeTemp(event)"
type="number"
name="celsius"
id="celsius"
placeholder="Enter Temperature"
class="input"
/>
</div>
<div class="temp-container">
<label for="fahrenheit">Fahrenheit:</label>
<input
onchange="computeTemp(event)"
type="number"
name="fahrenheit"
id="fahrenheit"
placeholder="Enter Temperature"
class="input"
/>
</div>
<div class="temp-container">
<label for="kelvin">Kelvin:</label>
<input
onchange="computeTemp(event)"
type="number"
name="kelvin"
id="kelvin"
placeholder="Enter Temperature"
class="input"
/>
</div>
</div>
<script src="index.js"></script>
</body>
</html>
Practice input values, number formatting, and javaScript calculations with these related projects.
Best matchRead form values and use them in the project logic.
Build a weight converter →
Format numeric results before displaying them on the page.
Build a loan calculator →
Turn JavaScript calculations into clear visual results.
Build a basic calculator →
Read form values and use them in the project logic.

Format numeric results before displaying them on the page.
Build a loan calculator
Turn JavaScript calculations into clear visual results.
Build a basic calculator