Create your own DIY security camera with motion detection, night vision, and remote viewing. No monthly fees, complete privacy, and expandable to multiple cameras.
Difficulty: ⭐⭐⭐ Intermediate | Time: 2-4 hours | Cost: $90-180 per camera
Quick Shopping List
Raspberry Pi (Choose One):
- Raspberry Pi 4 – Best for multiple cameras, $35-55
- Raspberry Pi 3 B+ – Good for single camera, $35
- Raspberry Pi Zero 2 W – Budget option, $15
Camera (Choose Based on Needs):
- Raspberry Pi Camera Module V2 – Standard daylight camera, $25
- Raspberry Pi Camera Module 3 – Latest model with autofocus, $30
- Raspberry Pi NoIR Camera – Night vision (requires IR illuminator), $30
- Arducam 5MP Camera with Case – Includes protective case, $35
Storage:
- SanDisk 128GB microSD Card – For OS, $15-20
- 1TB External USB Drive – For video storage (HDD), $40-50
- 1TB External SSD – Faster, more reliable (recommended), $60-80
Power:
- Raspberry Pi Power Supply 5V 3A – Long cord for flexible placement, $10
- USB Type-C Power Cable with Switch – For Pi 4, convenient on/off, $10
Case & Mounting:
- Pi 4 Case – Indoor setup, $8-10
- Pi 3 B+ Clear Case – Indoor setup, $8-10
- Weatherproof Camera Case – Outdoor installation, $15-25
Night Vision (if using NoIR camera):
- IR Illuminator for Night Vision – Extends night vision range, $15-25
Advanced Options:
- PoE HAT for Pi 4/3B+ – Power over Ethernet, single cable setup, $25-30
- PoE HAT for Pi Zero – With Ethernet & USB hub, $35-40
Total Cost:
- Basic (daylight, Pi Zero): ~$90
- Standard (Pi 4, night vision): ~$140
- Premium (Pi 4, SSD, PoE): ~$180
What You're Building
✅ Motion-triggered recording
✅ 24/7 monitoring with night vision
✅ Remote viewing via phone/computer
✅ Local storage (no cloud fees)
✅ Expandable to multiple cameras
✅ Smart home integration
Camera Options Explained
Camera Module V2: Great for daylight, 8MP, 1080p video, fixed focus
Camera Module 3: Latest version, autofocus, better low light, HDR
NoIR Camera: No IR filter, sees in complete darkness with IR illuminator, black & white night mode
Arducam with Case: Includes protective case, good all-around option
Recommendation: NoIR Camera + IR Illuminator for 24/7 security
Step-by-Step Setup
1. Install MotionEyeOS
- Download from: github.com/motioneye-project/motioneyeos/releases
- Flash to microSD card using Raspberry Pi Imager
- Choose image for your Pi model
2. Connect Camera
Power off Pi first!
- Locate camera port (between HDMI and USB)
- Pull up black clip gently
- Insert ribbon cable (blue side facing out)
- Push clip down to secure
3. Boot and Configure
- Insert SD card, connect ethernet (or Wi-Fi)
- Power on with Pi power supply
- Find Pi IP address (check router or use Fing app)
- Open browser:
http://[PI_IP] - Login: username
admin, password (blank)
4. Basic Setup
Set password:
- Menu → Settings → Admin Password
Configure camera:
- Resolution: 1920x1080 (1080p)
- Frame Rate: 15-20 FPS
- Quality: 75%
5. Enable Motion Detection
- Motion Detection → Enable
- Frame Change Threshold: 2-5%
- Configure alerts (email/webhook)
- Set recording to USB storage or SSD
6. Add Storage
- Plug USB drive or SSD into Pi
- Menu → Storage → Select USB device
- Recording Mode: Motion triggered (saves space)
- Preserve: 7 days (auto-delete older footage)
Night Vision Setup
With NoIR Camera:
- Install IR illuminator near camera
- Point IR LEDs in same direction as camera
- Test in complete darkness
- Adjust camera exposure if needed
Tips:
- More IR LEDs = longer range
- Position to avoid reflections
- Works through weatherproof case
Outdoor Installation
Using Weatherproof Case:
- Mount Pi and camera inside case
- Seal cable entry points
- Angle downward to prevent rain on lens
- Use long power cable if outlet is far
- Consider PoE HAT for single-cable installation
Power Over Ethernet (Advanced)
For clean, professional installation:
For Pi 4/3B+: PoE HAT
- Powers Pi via ethernet cable
- No separate power cable needed
- Includes cooling fan
- Requires PoE switch or injector
For Pi Zero: PoE HAT with USB Hub
- Adds ethernet + power
- 3x USB ports
- Compact solution
Remote Viewing
Option 1: VPN (Recommended)
- Set up VPN server (PiVPN)
- Access securely from anywhere
- No port forwarding needed
Option 2: Tailscale (Easiest)
- Install Tailscale on Pi and phone
- Automatic secure connection
- Works anywhere
Option 3: Port Forwarding (Not Recommended)
- Security risk
- Use VPN instead
Storage Recommendations
1TB USB Drive (HDD):
- More affordable
- Motion-only: 100+ days
- Continuous: 60-90 days
- Slower access
1TB SSD (Recommended):
- Faster, more reliable
- Better for continuous recording
- Silent operation
- Worth the extra cost
Multi-Camera Setup
Add more cameras:
- Set up additional Pis with cameras
- Menu → Add Camera → Network Camera
- Enter other Pi's IP and credentials
- View all cameras in one interface
Or use USB webcams as additional cameras on same Pi
Troubleshooting
No camera feed: Check cable connection, reboot Pi
Motion detection too sensitive: Increase threshold, mask busy areas
Poor night vision: Add more IR LEDs, adjust exposure
Storage filling up: Reduce retention days, lower resolution/FPS
Cost Comparison
DIY Raspberry Pi: $90-180 one-time, $0/month
vs. Commercial:
- Nest Cam: $180 + $6-12/month
- Ring: $180 + $3-10/month
- Arlo: $200 + $3-10/month
Savings: $50-120 per year + equipment savings
Tips for Best Results
Camera placement:
- Entry points (doors, windows)
- 8-10 feet high
- Avoid direct sunlight
- Cover driveways and walkways
For reliability:
- Use ethernet over Wi-Fi
- Quality power supply
- SSD over HDD for continuous recording
For best image:
- Clean lens regularly
- Proper IR illuminator placement
- Avoid reflective surfaces
What's Next?
- Add AI object detection (Frigate)
- Integrate with Home Assistant
- Set up cloud backup
- Add license plate recognition
- Multiple camera zones
Resources
- MotionEyeOS: github.com/motioneye-project/motioneyeos
- r/raspberry_pi
- r/homedefense
Build your security system today! Professional-grade monitoring without monthly fees.
Disclosure: Troy's Tech Corner participates in the Amazon Associates Program. We may earn a commission from qualifying purchases at no additional cost to you.