Self-contained, dependency-free ART method hooking for Android 8–15. ArtMethod-level, lock-free.
ArtHook is a C++ programming library for Android that lets developers intercept and replace Java methods at the system runtime level. It works by finding the internal structures that Android uses to store method information, then redirecting calls so your custom code runs instead of the original. The library can work across many different Android versions automatically, handles multiple threads safely, and provides a way to still call the original method if needed. An example use case shown is bypassing SSL certificate security checks in apps.
How It Works
You have an Android app and want to modify or observe how certain Java methods behave without rewriting the app itself.
You discover this library that can intercept any Java method and run your own code instead, while still letting you call the original.
You include this library in your Android project build, like adding any other code library to your app.
You pick any Java method in the app—maybe one that checks security certificates or handles data—and tell ArtHook to run your code instead.
Your code runs instead of the original, giving you full control over what happens.
Your code runs first, then you can still call the original method whenever you want.
ArtHook automatically handles the tricky parts—figuring out how the app's internal structures work, keeping things thread-safe, and making sure your replacement code gets called correctly.
The app now runs your custom code when those methods are called, while the rest of the app continues normally.
Star Growth
Repurpose is a Pro feature
Generate ready-to-use prompts for X threads, LinkedIn posts, blog posts, YouTube scripts, and more -- with full repo context baked in.
Unlock RepurposeSimilar repos coming soon.