JavaScript · Interactive Curriculum
Learn JavaScript Online
From Basics to the Browser
A free interactive JavaScript tutorial from fundamentals through arrays, objects, async/await, DOM events, browser APIs, and form validation.
1console.log("Hello, JavaScript!");Why Learn JavaScript?
Discover the benefits of learning JavaScript, the language of the web.
All JavaScript Lessons
Browse the complete ordered curriculum. Each lesson has a readable page you can link to and share.
Introduction to JavaScript
Start learning JavaScript from scratch. This beginner tutorial covers why JS powers the web and how to write your first program.
Variables and Data Types
Master JavaScript variables and data types including let, const, var, type coercion, and truthy/falsy values in this hands-on tutorial.
Functions in JavaScript
Learn how to create reusable code with functions
Control Flow
Learn JavaScript control flow with if/else, switch, ternary operators, and loops. Build programs that make decisions and repeat actions.
Data Structures
Learn how to organize data with JavaScript arrays and objects. Covers destructuring, spread operator, and essential array methods.
Array Methods
JavaScript array methods tutorial — master map, filter, reduce, find, some, every, and more with interactive examples you can edit and run
Destructuring and Spread
Learn JavaScript destructuring and the spread operator. Unpack arrays and objects to write cleaner, more expressive modern JavaScript.
Objects and Prototypes
Master JavaScript objects, the this keyword, and prototypal inheritance. Learn how JS shares behavior between objects under the hood.
Closures and Scope
Understand JavaScript closures and scope. Learn lexical scoping, the module pattern, IIFEs, and practical closure patterns for data privacy.
Async and Promises
Master asynchronous JavaScript with callbacks, Promises, and async/await. Learn to write non-blocking code and handle async errors.
Error Handling
Learn JavaScript error handling with try/catch/finally, custom error classes, and defensive programming techniques for robust code.
DOM and Events
Learn JavaScript DOM manipulation and event handling. Select elements, modify content, create dynamic pages, and respond to user actions.
Local Storage and State
Learn localStorage and sessionStorage to persist data in the browser. Manage simple application state without a framework.
Form Validation
Learn client-side form validation with JavaScript. Cover built-in validation, custom rules, real-time feedback, and accessible errors.
Modules and Bundling
Organize your JavaScript code with ES modules. Learn import/export syntax, default vs named exports, and dynamic imports for code splitting.
Testing and Debugging
Learn JavaScript testing and debugging. Write unit tests, use TDD, master console methods, and build reliable debugging strategies.
Web APIs and Fetch
Learn the JavaScript Fetch API to make HTTP requests, handle JSON responses, and build robust API clients with error handling.
Performance Optimization
Optimize your JavaScript with debouncing, throttling, memoization, and memory management
Capstone Project: Task Manager
Build a real in-browser Task Manager: render tasks with the real DOM, persist them across reloads with localStorage, and validate a real form. The pure-logic layers still run in the embedded playground.
Classes and Inheritance
Learn JavaScript classes and inheritance. Build reusable blueprints with constructors, methods, static fields, and extends for OOP.
Regular Expressions
Master regular expressions in JavaScript. Learn regex syntax, search and replace patterns, and practical validation techniques.
Date and Time
Master JavaScript's Date object to create, format, compare, and manipulate dates and times for building real-world applications.
Generators and Iterators
Learn JavaScript generators and iterators to produce values on demand. Unlock lazy evaluation, infinite sequences, and async patterns.
Proxy and Reflect
Learn JavaScript Proxy and Reflect to intercept object operations. Build validation, logging, and reactive data patterns.
Web Workers
Learn Web Workers to run JavaScript in background threads. Keep the main thread responsive during CPU-intensive tasks and data processing.
Frequently Asked Questions
- Can I learn JavaScript here for free?
- Yes. LearningJavaScript.org is free to use, with interactive lessons and a JavaScript playground that cover the fundamentals as well as arrays, objects, async code, DOM events, and browser APIs.
- Is this a good place to start as a beginner?
- It is built for that. You begin with variables, types, functions, and control flow, and only once those feel solid do the lessons move you into async programming, modules, testing, and browser APIs.
- Do I need to set anything up to run code?
- No setup at all. The playground runs your JavaScript right in the browser, so you can practice from the first lesson without installing Node or wiring up a project.
- What should I practice once I have the basics?
- Once variables and functions feel natural, the next things worth your time are arrays and objects, closures, async/await, DOM events, modules, fetch, and getting comfortable with debugging.