Block real-world advertisements using augmented reality.
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
Table of Contents
Augmented Reality (AR) Ad Blocker is an Android application that uses augmented reality and machine learning to detect and block real-world advertisements in real-time. When you point your phone's camera at billboards, posters, or other advertisements, the app automatically overlays them with a 3D stop sign (🚫), effectively "blocking" them from your view. The app integrates Unity's AR Foundation framework with a custom-trained YOLOv8 object detection model, executed on-device using Unity Sentis for inference.
| Welcome Screen | Ad Blocker Screen |
|---|---|
![]() |
![]() |
Before you begin, ensure you have the following installed:
- Unity Hub with Unity Editor 2022.3 LTS
Download from: https://unity.com/download - Android SDK (API Level 24 or higher)
- Android device with ARCore support
Check compatibility: https://developers.google.com/ar/devices - Git for cloning the repository
-
Clone the repository
git clone https://github.com/vijethph/augmented-reality-adblocker.git cd augmented-reality-adblocker -
Open project in Unity
- Launch Unity Hub
- Click "Open" and select the cloned project folder
- Unity will automatically import all required packages
-
Configure Android Build Settings
- Go to
File > Build Settings - Select
Androidplatform - Click
Switch Platform - Go to
Player Settings > Other Settings - Set Minimum API Level to Android 7.0 (API Level 24)
- Remove Vulkan from Graphics APIs (use OpenGLES3 only)
- Set Scripting Backend to IL2CPP
- Enable ARM64 architecture
- Go to
-
Install Required Packages (if not auto-installed)
- Open
Window > Package Manager - Install the following packages:
- AR Foundation (5.x)
- ARCore XR Plugin
- Unity Sentis (2.1 or later)
- Input System
- TextMeshPro
- Open
-
Build and Deploy
- Connect your Android device via USB
- Enable USB Debugging on your device
- Go to
File > Build Settings - Click
Build and Run
- Launch the application on your Android device
- Welcome Screen appears with app instructions
- Click the info button (ℹ) to view detailed usage instructions
- Tap START to begin the AR experience
- Point your camera at real-world advertisements (billboards, posters, signs)
- Hold steady for optimal detection (processes every 0.5 seconds)
- Watch as red prohibition signs automatically appear over detected ads
- Move around - the 3D overlay stays anchored to the advertisement
Distributed under the Apache License 2.0. See LICENSE file for more information.
Vijeth P H
- GitHub: @vijethph
- Project Link: https://github.com/vijethph/augmented-reality-adblocker
- Unity AR Foundation Documentation
- Unity Sentis Documentation
- Ultralytics YOLOv8
- Roboflow - Computer Vision Platform
- Blender 3D Creation Suite
- ARCore by Google
- Best-README-Template
- Inspired by real AR ad-blocking prototypes showcased on Reddit

