Get App Name
import android.content.Context; import android.content.pm.ApplicationInfo; import android.content.pm.PackageManager; import android.content.pm.PackageManager.NameNotFoundException; class Main { public static String getAppName(Context ctx, String pkgName) { try { PackageManager pm = ctx.getPackageManager(); ApplicationInfo appInfo = pm.getApplicationInfo(pkgName, 0); String label = pm.getApplicationLabel(appInfo).toString(); return label; } catch (NameNotFoundException e) { return ""; } } }