Capturing HAR for mobile apps

I want to capture the http archive files for mobile apps to benchmark their performances. How do I capture this on Android or iOS?