How to Make a Lie Detector That Actually Works

A basic lie detector measures changes in your body’s stress responses, specifically skin sweat, heart rate, and breathing, then displays those changes in real time. You can build a simple but functional version at home using an Arduino microcontroller and a few inexpensive components. The most accessible approach focuses on galvanic skin response (GSR), which tracks how much your skin’s electrical conductivity shifts when you’re nervous or stressed.

How Lie Detectors Actually Work

When someone feels stressed or anxious, their sympathetic nervous system kicks in. Sweat glands activate (even slightly), heart rate increases, and breathing patterns change. A lie detector doesn’t literally detect lies. It detects these physiological stress responses and assumes that lying produces more stress than telling the truth.

Professional polygraphs measure at least three channels simultaneously: skin conductance, cardiovascular activity, and respiration. A DIY version can realistically capture one or two of these. Skin conductance is by far the easiest to measure at home, since it only requires two contact points on the fingers and a simple circuit. The electrical resistance of skin ranges from about 10 kilohms when someone is stressed and sweating to 10 megohms when fully relaxed, a massive swing that’s easy to pick up with basic electronics.

Components You Need

For a skin-conductance-based lie detector, the parts list is short:

  • Arduino UNO (or any Arduino-compatible board)
  • Three 330-ohm resistors
  • One 2K-ohm resistor
  • Electrical wire
  • Tin foil and hook-and-loop tape for finger electrodes
  • LEDs (optional, for a visual indicator)

If you want to add a heart rate channel, a pulse sensor module (widely available for a few dollars) connects directly to an Arduino analog pin. For the full setup including the board and wires, expect to spend under $30.

Building the Skin Conductance Sensor

The core of your lie detector is a simple voltage divider circuit. One wire connects to the Arduino’s 5V output pin, and the other connects to analog input pin A0 through the 2K-ohm resistor. The two free ends of these wires are your electrodes. Wrap small squares of tin foil around the tips of each wire. These foil pads attach to the subject’s index and middle fingers using strips of hook-and-loop tape to keep solid contact with the skin.

When a small voltage passes through the skin between the two fingers, the Arduino reads how much current flows. More sweat means lower skin resistance, which means a higher voltage reading at pin A0. The output voltage is inversely proportional to skin resistance: a stressed, sweating person might produce readings near 1.7 volts, while a relaxed person drops below 0.2 volts. Your Arduino’s analog-to-digital converter reads values from 0 to 1023, giving you plenty of resolution to see changes in real time.

You can add three LEDs (green, yellow, red) through the 330-ohm resistors to give a visual readout. Program the Arduino to light green below a certain threshold, yellow in the middle range, and red when the reading spikes.

Writing the Code

The Arduino sketch is straightforward. Read the analog value from pin A0 in a loop, print it to the serial monitor, and compare it against your threshold values. A basic version looks like this: read the sensor every 100 milliseconds, calculate a running average over the last 10 readings to smooth out noise, and trigger your LED outputs when the smoothed value crosses your set boundaries.

The serial monitor or serial plotter built into the Arduino IDE gives you a live graph of the readings, which is the most useful way to watch responses in real time. You’ll see the line spike upward within one to three seconds after a stressful question, then gradually drift back down as the person calms.

Establishing a Baseline

No lie detector works without a baseline. Before asking any meaningful questions, you need to record what the subject’s normal resting readings look like. Professional polygraph examiners spend 10 to 15 seconds observing initial readings and letting any startup response fade before the first question.

To calibrate your DIY version, have the subject sit still and relaxed with the electrodes attached for at least 30 seconds. Note the average reading during this period. Then ask a few neutral, emotionally flat questions (“Is today Tuesday?” “Are you sitting in a chair?”) and record those readings. This gives you the person’s individual baseline, which is critical because people differ significantly in their resting skin conductance. There is no universal normal value.

Once you have a baseline, ask a question you know the person will lie about (have them pick a card and deny which one they chose, for example). The spike you see on that known lie becomes your reference point for interpreting later responses.

Asking the Right Questions

Professional polygraphs use a specific questioning structure called the Comparison Question Technique. It alternates between three types of questions: irrelevant questions (neutral, no emotional weight), comparison questions (vaguely uncomfortable topics most people would feel uneasy about, like “Have you ever lied to someone you care about?”), and relevant questions (the actual questions you’re testing).

The logic works like this: a truthful person feels more stress on the comparison questions, because they know they’re probably being a little dishonest there, while telling the truth on the relevant ones. A deceptive person shows stronger reactions to the relevant questions, because those are the ones that actually threaten them. You’re looking at the relative difference in response between these question types, not the absolute readings.

Space questions about 15 to 20 seconds apart. This gives the physiological response time to rise and fall back toward baseline before the next question. Rushing through questions makes the data unreadable because responses overlap.

Adding a Pulse Sensor

If you want a second channel, a clip-on pulse sensor module reads heart rate through the fingertip or earlobe. Wire it to a second analog pin on the Arduino and read it alongside your GSR data. Emotional stress, anger, and anxiety all cause measurable heart rate variations. You’re looking for a bump of several beats per minute above the baseline in the seconds after a relevant question.

That said, heart rate is the easiest channel for someone to manipulate. A subject can slow their breathing or tense muscles to influence cardiovascular readings. Professional polygraph research has found that cardiovascular measures show the strongest effects from countermeasures, meaning they’re the least reliable channel if someone is actively trying to beat the test.

Why Accuracy Is Limited

Even professional polygraphs have significant accuracy limitations. A comprehensive meta-analysis of comparison question polygraph tests found a moderate overall effect size of 0.69, which means the test performs meaningfully better than random guessing but falls well short of certainty. It outperforms human intuition at detecting deception, but that’s a low bar since people are generally poor at spotting lies.

Simple countermeasures can defeat the test. A study with 120 participants found that both physical countermeasures (biting the tongue or pressing toes to the floor during control questions) and mental countermeasures (counting backward by 7) each allowed roughly 50% of guilty subjects to beat the polygraph. These techniques were difficult to detect either through the instruments or by observation.

Your DIY version, measuring only one or two channels instead of the three or more used professionally, will be less accurate still. It works well as a science project, a party trick, or a way to learn about psychophysiology. It is not a reliable way to determine whether someone is actually lying.

Legal Restrictions to Know About

In the United States, the Employee Polygraph Protection Act prohibits most private employers from using lie detector tests for pre-employment screening or during employment. Employers cannot require, request, or even suggest that an employee or applicant take one. They also cannot use the results to make hiring or disciplinary decisions. Exceptions exist for security firms, pharmaceutical companies, and specific investigations involving theft or economic loss, but even those are subject to strict rules including licensed examiners and limits on how results can be disclosed.

Using your homemade device on friends or family for fun is fine. Using it in any context where results could affect someone’s job, legal standing, or reputation crosses into territory with real legal and ethical consequences.