Introduction: Scary, Motion-sensing, Moving, Halloween Skull

About: I love science, electronics, programming, and making. Visit my website ^ for more info.

Imagine this: You are an innocent trick-or-treater walking around your neighborhood. You're walking down someone's walkway with candy in mind. You notice jack-o-lanterns on the doorstep, as well as the usual halloweens decorations: fake spider-web, plastic spiders, plastic skulls, etcetera. You ignore them, you just want the candy. You're about halfway down the walkway when you hear a whir on your left. You turn your head towards the sound just in time to see the eyes in one of those plastic skulls start to glow red, then yellow! The glow illuminates gruesome blood covering the skull, and suddenly the skull starts to move, and turns it's head to look straight at you!

This Halloween prop/decoration can be made within about an hour or two, and there's nothing complicated about it. You can find all the materials on Ali Express or Ebay for $10 or less from low-cost international suppliers (although if Halloween is close you might not be able to wait for the very long shipping times).

The skull is very simple: There are LEDs in the eyes, and the whole skull sits on top of a servo motor hidden beneath it. A simple PIR motion sensor detects movement nearby and activates the servo, which rotates the skull, and activates the LEDs. The whole thing is controlled by an arduino (or other microcontroller).

Please note: please view all the photos for each step. The photos will make my instructions for each step much easier to understand.

Step 1: Materials Needed

You will need the following materials & supplies in order to build the skull.


  • 1x Arduino Uno or other arduino-compatible microcontroller (like arduino pro mini, sparkfun redboard, etc.) (you can buy it from Ali Express or Amazon)
  • 1x plastic Halloween decor plastic skull, from Walmart or any store with Halloween decor. It should be at least 4 or 5 inches tall. You could also possibly find one to 3d print (make sure it's hollow!!!!!!!) or you could buy one from Amazon (I have not tried that skull).
  • 1x 9g micro servo from Ali Express or Amazon
  • 1x PIR sensor module HC-SR501 from Ali Express or Amazon
  • 2x generic 5mm LEDs, color of your choice. These will be for the eyes; I chose to use red and yellow. From Ali Express or Amazon
  • 2x generic resistors, ~330Ω (ohms). From Ali Express (Make sure you select 330R when ordering) or Amazon
  • hookup wire, at least 4 feet, for connecting leds to arduino. Any relatively thin electrical wire will work. Get some from Ali Express or Amazon
  • jumper wires: 3x female-male, 3x male-male, for connecting PIR and servo to arduino. Get some from Ali Express or Amazon


  • soldering iron (optional), will be used to solder wire to LED leads.
  • glue gun, or other similar glue. Will be used to glue skull onto servo, and will optionally be used to glue wire to LED leads.
  • drill or hand drill or something else to drill out eye holes for the leds. It doesn't matter what you use, you just need to be able to make an approximately 3mm diameter hole straight through the eyes on your skull.
  • razor knife, knife, small saw, or something else to cut a hole in the bottom of your skull. The hole must be big enough to reach your fingers through it.
  • some masking or duct tape
  • USB cord for arduino
  • computer with Arduino software installed. Get the Arduino IDE here.

That's all! Let's build it now!

Step 2: Preparing the Skull

The first step is to drill out the eyes and bottom of the skull. The eye holes must be big enough for two wires to pass through and a little bit more, but they must stay smaller than the diameter of the LEDs. This is because we don't want the LEDs to slip through the holes. So, if you are using 5mm LEDs, then about a 3mm hole should work. I used a little hand drill to drill them out.

The hole on the bottom must be big enough to reach a finger into, because you need to reach a finger or something else into the skull to fish the wires from the LEDs out of the inside of the skull. The bigger the hole is, the easier it will be to fish the wires out. I used a razor knife to cut the hole.

Step 3: Prepare the LEDs

Now, we need to install the eyes. First of all, prepare your LEDs by attaching their leads to some wire. The best way to do this would be to solder one end of a piece of wire to the LED leads, but if you don't have a soldering iron, then you could just wrap the wires around the leads very tightly and then glue or tape them to make sure the wire doesn't come off. Don't worry about polarity but make sure you use enough wire! you should use about 1 foot of wire for each lead, so about 2ft per LED. There must be enough wire for each lead so that the wire can reach from the eyes, through the inside of the skull, out the hole in the bottom, and to the arduino.

After you attach the wires to the LEDs, take some tape and wrap it around ONE of the leads. Then, wrap the tail from that piece of tape around BOTH LEDs (see the pictures). The tape is simply there to insulate the leads from one another.

After that, test your LEDs: take one of your resistors and wrap the wire from one of the LEDs around the end (see picture). then, plug the wire and other end of the resistor into the arduino like shown in picture (wire into GND, resistor into 5V). Plug in your arduino using a USB cable! If the LED doesn't light, switch the wires around (wire to 5V, resistor to GND). If the LEDs don't light either way, recheck your connections.

Once both LEDs successfully light, remove the resistors and move on.

Step 4: Install the LEDs

Take the ends of the wires of one of the LEDs and feed them through the eye holes. Push the wires through completely and then push the LEDs right up to the holes so that the base of the LEDs are flush with the back of the skull's eye sockets (you might need to remove a bit of the tape on the LEDs).

Now comes the hard part: fishing the wires out the bottom of the skull. I used a metal skewer to reach into the hole and pull the wires to the edge, then I reached in with my finger and pulled them out (see pictures). Just keep trying until you get them out the bottom.

Step 5: Mount the Skull Onto the Servo

Now take one of the attachments that came with your servo. You will need to glue it on to the bottom of your skull, preferably using a glue gun. Glue it as close to the middle as you can, but make sure that there is room around it for the servo (see the picture). Plug the servo into the attachment and make sure you can rotate it 180 degrees without it hitting the skull, then remove the servo for now.

Step 6: Wire and Center the Servo

Take the 3 male-to-male jumper wires and connect one end to the servo and the other to the arduino like this (see picture):

red servo wire (+) to 5V on arduino

brown or black servo wire (-) to GND on arduino

orange or yellow servo wire (signal) to pin 6 on arduino

Now, open the arduino IDE (see step 1). If you've never used arduino before, check out this guide before continuing. Plug in your arduino with a USB cable and upload the following code to the arduino.

#include <Servo.h>
#define servopin 6
Servo servo;
void setup() {
void loop() {delay(500);}

You should hear/see the servo rotate. The servo is now rotated to the middle of it's range.

You can now attach the servo to the attachment glued to the skull, and you might want to temporarily tape/glue the bottom of the servo to your workbench/table so that the skull is held steady for the next steps. See the picture.

Step 7: Wire the LEDs

First, we need to attach the resistors. The resistors are there to "resist" the current (electricity) to protect the LEDs. Without the resistors, the LEDs might consume to much electricity and burn out.

First, make sure you know which wires are which (You might have to take the skull off the servo) - there should be four wires coming out the bottom of the skull, 2 for each LED. Take one wire from one of the LEDs and solder it to a resistor. If you don't have a soldering iron, wrap the end of the wire very tightly around one of the resistors legs, then secure it with tape or glue (see picture). Then do the same for one of the wires coming from the other LED.

Now, I recommend you tape the wires for the same LED together, so you can tell which wires are for the same LED (see picture). Then put your skull back onto the servo (which you should have glued or taped, with double-sided tape, to your table).

Now, wire your LEDs like this:

First resistor to pin 11 on the arduino

First wire (the wire taped to the first resistor) to pin 12 on the arduino

Second resistor to 9

Second wire to 8

Now, to test the LEDs, plug in the arduino and upload the following code:

const byte LED1 = 9;
const byte LED2 = 11;
const byte GNDPIN1 = 8;
const byte GNDPIN2 = 12;
void setup() {
  pinMode(LED1, OUTPUT);
  pinMode(LED2, OUTPUT);
  pinMode(GNDPIN1, OUTPUT);
  pinMode(GNDPIN2, OUTPUT);
  digitalWrite(GNDPIN1, LOW);
  digitalWrite(GNDPIN2, LOW);
  digitalWrite(LED1, HIGH);
  digitalWrite(LED2, HIGH);
void loop() {delay(100);}

Both LEDs should light. If they don't, try switching each resistor-wire pair around until they do. Also, check your connections. I had to tape my wires to the the arduino because they kept falling out (see picture).

Step 8: Wire the PIR

This is the easiest step: wire the PIR (HC-SR501) sensor.

Before you wire it, look at the bottom of the PIR: there are two orange or yellow "knobs" on one of the sides (see the picture). Using a small screwdriver (or your finger), turn both orange knobs counter clockwise as far as they can go (see the picture). Next, find the little yellow or orange "jumper" sitting on two of the headers (thick wires) sticking up from the bottom of the PIR (see picture). Make sure it is sitting on the left two headers as seen from that side, or the innermost two headers (see pictures).

Now position the pir so that the knobs are at the back and the bottom of the pir is face up. Take the 3 female-male jumper wires and connect the PIR to the arduino like in the first picture:

left pin on PIR to 5V OR IOREF on arduino

middle pin on PIR to pin 7 on arduino

right pin on PIR to GND on arduino

Great! now your PIR is wired.

Step 9: Activate the Skull

Yeah! The skull is almost done. Now, you should make sure that everything is still wired correctly, and make sure you have the servo attached to your table with the skull on top. Make sure everything is out of the way except the arduino and wires - because the skull is about to start moving! Also, make sure the top (the rounded side) of the PIR is roughly aimed forward, in your direction.

Copy and paste the file halloween_skull.ino (You can also view halloween_skull on github) into arduino, and upload it to your arduino. Then, immediately step back about 10 steps, stop moving and wait. After about 20 seconds (the PIR needs at least 20 seconds to initialize), you will see one of the eyes flash on then off - when this happens, you can walk towards your skull. Soon after you start moving, as long as you did everything right, the skull's eyes will light up and it will start to move. IT WORKS! IT WORKS! Stop moving and soon after, the skull will settle down and it's eyes will shut off. When you move again, the skull will move again.

That's it! We're done! In the next step I will talk about calibrating the skull, as well as setting it up outside in your yard.

Step 10: Calibrating the Skull

On Halloween, you can mount your skull outside however you want. I attached my skull's servo to the top of a garden post using double-sided foam tape and attached the arduino to the back of the post right below the skull, where people walking up our walkway couldn't see it. I used a 9 volt battery, which I attached below the arduino to power the arduino. I then attached the PIR to the side of the post so it's rounded side was aimed right down our walkway (towards our front gate). I did all this with double sided tape so I could easily remove everything after Halloween. It works pretty well; all people see when they come in the gate is an innocent, normal plastic skull decoration sitting on a post.


Calibration isn't really necessary, but you might want to adjust the skull if it is triggering too late, or too soon. You can adjust the sensitivity of the PIR by adjusting the orange or yellow knob on the LEFT, when viewing the knobs on the PIR with the bottom up. In my picture, it is the bottom knob. To reduce the sensitivity (range), turn the calibration knob clockwise. To increase the sensitivity, turn the calibration knob counterclockwise.

I found that I needed to re-calibrate my skull when it got dark outside.

One more thing: you can also shield your PIR from certain sides by taping or gluing cardboard to one side of it. This acts as a shield if, for example, you only want your skull to activate for people on one side of the skull.

Step 11: Conclusion

Congratulations on finishing a working, motion-detecting, moving, Halloween skull decoration!

Feel free to try modifying my code or upgrading your skull. You could even try adding a speaker so your skull can make noises. If you come up with some great idea, leave a comment!

If you have any questions, please leave a comment and I will reply and try my best to help you as soon as I can.

Also feel free to check out my website, which sometimes has other little tutorials and things that I don't have on Instructables.

Thank you everyone!

Halloween Contest 2018

Participated in the
Halloween Contest 2018