• Don Peter

Detect memory leaks in iOS (Objective-C & Swift)

Updated: Dec 6, 2019

Memory leak is one of the most dreadful issues developers fear. It's even bigger challenge for mobile app developers as very often the device where the issue manifests is out of their reach. Most of the time developers will not even get crash reports caused by memory leaks. They usually manifest in the form of EXC_BAD_ACCESS.

Tools like XCode Leaks Instrument for iOS help developers identify such leaks during development time itself. But what is the guarantee that all such leaks are identified and all possible use-cases are tested properly? There is no guarantee, and that is the hard truth.

So what if the developer and the tester missed some use cases and there are memory leaks happening in production? Here is where Finotes help the developer to get notified about the issue in real-time and that too with as much relevant data as possible so that (s)he can reproduce the bug.

The framework can detect memory leaks in view controllers just by extending ViewControllers from ObservableViewController provided by Finotes.


Alternatively, developers can call Fn.watchLeaks() API in viewDidDisappear function within ViewControllers to allow finotes to detect leaks.


Documentation for Objective-C & Swift for details on how to use Finotes to track memory leaks.


Finotes report bugs to the dashboard with important data such as activity trail, device info, and device state info. This will help the developer to be aware of the leaks happening in their app that is running in their users' devices and also helps them to reproduce the memory leak.

Here is a screenshot of such a leak detected by Finotes in a live app.


With such reports, developers are notified of the occurrence of a memory leak in a ViewController. Developers can then use the Leaks instrument to drill down the corresponding ViewController for the leak.

Apart from memory leaks, Finotes detects API call issues, frame rate issues, abnormal memory usage, crashes, exceptions, function failures & delays. It also has the capability to report custom issues.

The memory leak detection is available in our iOS Framework starting from version 3.1.0. For knowing more about how Finotes detects memory leaks in Android apps, read the blog How to detect bugs in Android.

Visit finotes.com to know more about Finotes. Detailed documentation is available at docs.finotes.com.