🔌 Logic Circuit Builder

Place gates · Drag from a pin to wire them together · Click a switch to toggle it

Place / Tool

Actions

Circuit status

Gates 0
Wires 0
Solver stable

How to build

1. Pick a component from the palette, then click empty canvas to drop it.
2. Drag from a small circle (a pin) on one gate to a pin on another to wire them — signal flows from a gate's right-side output to another gate's left-side input.
3. Click a switch to flip it between 0 and 1. Lit green wires carry a 1.
4. Select "Select", click a part, press Delete (or the button) to remove it.
5. Feedback loops (an output wired back into its own input chain) are solved iteratively — a stable loop (like a latch) settles, an unstable one is flagged.

🔌 Logic Circuit Builder

Drag AND, OR, NOT, XOR, NAND and NOR gates onto the canvas, wire them together, and toggle switches to drive a real graph-based boolean solver — including combinational-loop detection for latch-style feedback circuits.

🔬 What It Demonstrates

Every wire and gate you place becomes a node in a real dependency graph. A topological sort evaluates acyclic chains exactly; any feedback loop (like a cross-coupled NOR latch) is solved by iterative relaxation, converging to a stable state or being flagged as an unresolved oscillation.

🎮 How to Use

Pick a component from the palette and click the canvas to drop it. Drag from a pin on one gate to a pin on another to wire them. Click a switch to flip 0/1. Select "Select" and press Delete to remove a part. Try the Half-Adder and SR Latch presets.

💡 Did You Know?

Cross-coupling two NOR gates (or two NAND gates) makes an SR latch — the simplest circuit that can remember one bit. Every flip-flop in every processor's registers is built from exactly this kind of feedback loop.

About this simulation

Written by MySimulator Team · Reviewed by MySimulator Editorial Review

Last updated: 13 September 2026

This is a genuine logic-circuit builder: you place AND, OR, NOT, XOR, NAND and NOR gates on a canvas, wire their inputs and outputs together by dragging between pins, and drive them with toggleable switches. Under the hood the circuit is a real directed graph — every wire is an edge from one gate's output to another's input — and a topological solver walks that graph to evaluate the actual Boolean function of your circuit, handling arbitrarily long gate chains correctly.

🔬 What it shows

Placing gates and dragging wires builds a real dependency graph. Each frame, a Kahn's-algorithm topological sort evaluates every acyclic part of the circuit exactly, in dependency order — so a chain of ten gates feeding into each other computes correctly, not just single isolated gates.

🎮 How to use

Choose a component from the palette and click the canvas to place it. Drag from a small pin circle on one gate to a pin on another to connect them — signal flows from a gate's output (right side) into another gate's input (left side). Click a switch tile to flip it. Select the "Select" tool to drag parts around or delete them.

💡 Did you know?

Wiring an output back into an earlier input creates a combinational loop. This builder detects that automatically: it iterates the loop's equations until the values settle (as a real SR latch does, holding one bit of memory) or, if they never settle, flags the gates involved as oscillating rather than silently freezing or crashing.

Frequently asked questions

Is this a real logic simulator or just an animation?

It is a real simulator. Every gate and wire you place becomes part of an actual graph data structure, and a topological-sort algorithm evaluates true Boolean logic (AND, OR, NOT, XOR, NAND, NOR) through that graph every frame — it is not a pre-scripted animation.

What happens if I wire an output back into its own input chain?

That creates a combinational loop. The solver switches to iterative relaxation for the affected gates: it repeatedly recomputes their values from the current signals until they stop changing. A stable feedback circuit (like an SR latch) settles into a fixed state; a circuit that can never settle (like a single inverter looped to itself) is marked as oscillating with a "?" and a red highlight.

Can I build multi-gate circuits like an adder?

Yes — use the "Load: Half-Adder" preset to see a genuine two-input, two-output circuit (XOR for the sum bit, AND for the carry bit) or build your own by chaining any of the six gate types together.

How do I remove a gate or a wire?

Switch to the "Select" tool, click the gate to select it (its outline turns orange), then press Delete or use the "Delete selected" button — this removes the gate and every wire attached to it. To remove a single wire, drag from its destination pin to empty space.

How is this different from the 3D Logic Gates Simulator?

The 3D version lets you explore one gate at a time with its truth table. This 2D builder is a full circuit construction tool: you assemble multiple gates into a real wired network and watch signals propagate through the whole graph, including feedback loops the single-gate simulator can't represent.