A 3D circuit simulator for kids that runs in the browser.
Drag parts onto the board, join them with wires and watch lamps glow, motors spin and screens light up.
Then tell the AI board what to do, in plain words.
111 parts · 213 example projects · 69 workshop tools · 15 missions · 3 languages · free and open source
Build a circuit, then ask the AI board: “Make the light fade in and out slowly.” (The local model's thinking time is cut from the clip.)
Everything inside (every part, board and example shelf)
- Power: batteries from 1.5 to 12 V, a solar panel, a bench power supply, a lemon battery (three lemons just light a red LED), a coin cell, a hand dynamo and a USB power bank.
- Boards: Arduino Uno, Nano and Mega, ESP32, ESP8266, Raspberry Pi Pico, micro:bit, Raspberry Pi, the AVR chips ATmega328P, ATmega32 (ATmega16) and ATtiny85 with register-level AVR C, and an STM32 Blue Pill. Each pin can be on, off, blinking, taking turns, fading or following a sensor, and the board shows the real code for what you chose.
- Boards from the real world: a car's engine computer (ECU), a factory PLC that shows its program in Structured Text, and an oil well's RTU, plus an industrial pressure gauge.
- Messages and networks: SMS, Wi-Fi, Bluetooth and LoRa modules, a GPS, and the CAN bus of cars and RS-485 / Modbus of factories.
- AI board: a board you talk to: "make the red light blink", "turn the lamp on when it gets dark".
- Switches and knobs: switch, push button, stair switch, micro switch, dimmer, knob (potentiometer), joystick and relay.
- Electronic parts: resistor (with a colour-code lesson), capacitor, diode, Zener diode, transistors, MOSFET, optocoupler, fuse and voltage regulator.
- Chips and logic: NOT, AND, OR, XOR, NAND and NOR gates with a live truth table, a memory latch, a light-chaser counter, a comparator, a 555 blinker and a motor driver.
- Light, sound and motion: lamp, LED, RGB LED, motor, vibration motor, buzzer (a beep or a real police siren), speaker, electric bell, heating element, electromagnet, solenoid, servo, laser, infrared LED, traffic light, warning beacon, LED bar graph, fan and a water pump with moving water.
- Sensors: light, temperature, tilt, magnet, distance, motion, sound, smoke, soil, touch, flame, rain, water level, humidity, obstacle, line, pressure, heartbeat and knock.
- Screens: number displays, text and colour screens, LED matrices and LED walls of any size.
- Meters: a multimeter, a logic probe, a voltmeter, an ammeter and an oscilloscope.
- Things that go wrong, safely: too many volts burn a lamp, an LED without a resistor burns out, a wire straight across a battery makes a short circuit, and a fuse blows to protect the rest. Nothing can really break or get hot, so kids can try anything, make mistakes and learn why.
- 213 example projects on seventeen shelves, among them 21 for cars, 21 for factories, 12 for oil and gas, 25 home appliances that show how they work inside (washing machine, fridge, vacuum cleaner, juicer, mixer, toaster, iron, samovar …), and 11 that you talk to, with search and an easy / medium / hard filter.
Circuit Lab is built in English, Persian and Arabic from the ground up, so a child in Tehran, Muscat or London gets the same app in their own words.
- Everything in all three: the board, all 111 parts and their lessons, 213 example projects, 15 missions, the Toolbox and its quiz, and every tip and warning.
- Real right-to-left: in Persian and Arabic the whole app mirrors, from the panels and menus to the sliders and arrow keys, while formulas like V = A × Ω still read correctly.
- A font made for each script, and Persian digits where Persian children expect them.
- Search that understands you: Arabic and Persian spellings of the same letter (ي / ی, ك / ک) find the same thing.
- An AI that speaks your language: the AI board understands requests in any of the three and answers in the app's language.
The AI board uses a language model that runs on your own computer with Ollama. No account and no cloud: the child's words stay at home.
- Install Ollama from ollama.com and open it.
- Download a model once, for example
ollama pull gemma3:4b. - In Circuit Lab, add an AI board (or open an example from the Talk to AI shelf) and press Ask on its card.
If something is missing, the AI panel shows simple steps to fix it.
- Online at circuitlab.app, on a computer, tablet or phone.
- Install it like an app from the browser's menu ("Install" or "Add to Home Screen").
- Works offline after the first visit, and the board is saved automatically.
You need Node.js 22.12 or later.
git clone https://github.com/circuitlab-app/circuitlab.git
cd circuitlab
npm install
npm run dev # opens on http://localhost:5173| Command | What it does |
|---|---|
npm run dev |
Starts the app with hot reload |
npm test |
Runs the unit tests (Vitest) |
npm run lint |
Checks the code with oxlint |
npm run build |
Type-checks and builds the site into dist/ |
Built with React 19, TypeScript, Vite, React Flow, three.js (React Three Fiber), Tailwind CSS, shadcn/ui and Zustand. The circuit solver is a small nodal-analysis engine in src/circuit/solver.ts. docs/DEVELOPMENT.md explains how the simulation, the 3D models and the AI board work.
Ideas, bug reports and pull requests are welcome.
- Found a bug or have an idea? Open an issue, with a screenshot if you can.
- Want to add something? Adding things lists the steps for a new part or a new language. Example projects live in
src/circuit/presets.ts. - Before a pull request, run
npm test,npm run lintandnpm run build, and add any new words to all three dictionaries insrc/i18n/(English, Persian and Arabic).
If Circuit Lab helps a child you know, a ⭐ on GitHub helps other people find it.
Circuit Lab is a product of SBC · sbc.om · released under the MIT License.













