Geek Dashboard

How-To's, Smartphones, News and Reviews

  • Home
  • News
  • Smartphones
    • Android
    • iOS
  • Computers
    • Windows
    • macOS
  • Internet
  • Reviews
You are at Home » Mobiles

A Gradual Guide To Monetize An iPhone App Via iAd

Last Updated on March 27, 2020 by Emily Heming 1 Comment

Application monetization is an absolute way of earning money through an application. And Apple iOS serves the best medium for making money by monetizing application for in-app purchase.

The recent reports and surveys have dictated that iOS platform has generated over 85 percent more revenue than the Android platform. This remarkable difference proves that the Android platform is better for advertising purpose whereas the iOS platform is great for in app purchases.

iAd

If you have successfully created your iOS application, you probably are interested in learning how to monetize an iOS app. Along with several frameworks, APIs, SDKs, etc. Apple features an iAd platform that enables app publishers to easily monetize their apps. With this the publishers can either choose to add a banner ad, full-screen ad or both types of ads into the iPhone application.

How to monetize an iOS application with iAd and make money from it

Here is a comprehensive guide that shows how one can efficiently integrate Ad banners in their iPhone application.

1: First Things First: Get yourself registered for iAd

For accessing the iAd platform, you will need to enroll yourself under the Apple iOS Developer program; it will charge an affordable annual membership fee and that would be completely worthy as you are going to monetize your iOS application.

After enrolling in the program, you need to set up your contracts by logging into your iTunes Connect account. Click on the next screen and request for the “iAd App Network”. Then after doing so, fill in the mandatory fields and review the contract and agree to the mentioned terms and conditions (if there is nothing fussy).

terms and conditions

Fill in the pending contract details by going back to the Contracts screen. The system will automatically guide you through the setup process for each info.

in process

2: Go Thoroughly Through The Terms Used In The iAd Setup Guide

The iAd Setup Guide features some key points that have explained below.

  • Join the iAd App network in order to use the iAd platform in your application. This is what we have done in the 1st
  • A part of the screen is consumed by the banner views to showcase a banner Ad. Basically the banner ad is displayed at the bottom of the screen. And in this integration, we will make it visible only when it has been downloaded completely otherwise, not.
  • Full-screen ads offers a large space and look amazing when accessed over large-screen iOS devices. Another way of integrated ads in an application is using a full-screen ad. You may integrate this type of ad as an entirely dedicated page within a magazine application.
  • Interrupt the not-so-important applications for a few seconds when a user is interacting with the in-app advertisements.
  • If an ad gets canceled by the users, it will leave a negative impact on your application.
  • After integrating the iAd, validate your iAd support by testing the execution of the integrated ad before launching the application publicly in the Apple App store.

3: Steps To Be Followed For Integrating The Banner Ad At The Bottom Of Your Application

Here, I will explain you step by step how to integrate a banner ad

To create a sample project, first you will need to navigate to the “Single View Application” . After doing so you will get a form, fill in the requite fields and submit the details.

add a banner ad

Step A: How to add iAd framework to the Xcode project

how to monetize an iPhone app

Under the “General” option, navigate to the “Project Settings”. Then, at the bottom of the page, you can find a list of options including “Linked Frameworks and Libraries”.

Expand the associated list attached to this option and look for iAd framework. Select it to add it into the project, now you can deploy the iAd classes in your project.

choose framework to monetize iPhone application

Step B: How to create, initialize and integrate the object “AdBannerView” to the view

Open the ViewController.m and the below mentioned chunk of code under the “viewDidLoad” method.

Code Snippet:

#import "ViewController.h"

#import <iAd/iAd.h>

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad

{

[super viewDidLoad];

}

- (void)viewDidAppear:(BOOL)animated

{

[super viewDidAppear:animated];

ADBannerView *adView = [[ADBannerView alloc] initWithFrame:CGRectMake(0, self.view.frame.size.height - 40, 290, 40)];

[self.view addSubview:adView];

}

In the aforementioned piece of code, the iAd framework is imported, so as to get an access to its classes. And, the “viewDidAppear” method has been overriden to assign the desired size and position to the “AdBannerView” object. After initializing its value, it has been added to the view.

Step C: How to make the banner ad animate while fetching an ad successfully

  • Identify and notify the “ViewController” whenever a banner has been fetched successfully. To notify the “ViewController“ object about each successful fetching of a banner, you will need to make the object conform to the “AdBAnnerDelegate” To do this you can add the lines of code mentioned below in the “ViewController.h”.

Code Snippet:

#import <UIKit/UIKit.h>

#import <iAd/iAd.h>

@interface ViewController : UIViewController<ADBannerViewDelegate>

@end
  • Now, you will need to modify the code a bit in the “ViewController.m”.

Code Snippet:

#import "ViewController.h"

@interface ViewController ()

{

BOOL _bannerIsVisible;

ADBannerView *_adBanner;

}

@end

@implementation ViewController

- (void)viewDidLoad

{

[super viewDidLoad];

}

- (void)viewDidAppear:(BOOL)animated

{

[super viewDidAppear:animated];

_adBanner = [[ADBannerView alloc] initWithFrame:CGRectMake(0, self.view.frame.size.height, 290, 40)];

_adBanner.delegate = self;

}

If we will compare the code modification for ViewController.m from step B to C, it can be observed that –

  • Since iAd framework has been imported in the ViewController.h, it has been removed from here.
  • To track the banner availability some additional instance variable has been included.
  • The “adBanner” object has been created and assigned the instance var.
  • To refer to the “ViewController” object the the delegate for the banner has been set as “self”.
  • To notify the successful downloading of an ad, the AdBanner delegate has to be deployed as mentioned in the below chunk of code.

Code Snippet:

- (void)didReceiveMemoryWarning

{

[super didReceiveMemoryWarning];

}

- (void)bannerViewDidLoadAd:(ADBannerView *)banner

{

if (!_bannerIsVisible)

{

if (_adBanner.superview == nil)

{

[self.view addSubview:_adBanner];

}

[UIView beginAnimations:@"animateAdBannerOn" context:NULL];

banner.frame = CGRectOffset(banner.frame, 0, -banner.frame.size.height);

[UIView commitAnimations];

_bannerIsVisible = YES;

}

}

- (void)bannerView:(ADBannerView *)banner didFailToReceiveAdWithError:(NSError *)error

{

NSLog(@"Failed to retrieve ad");

}

@end

Now, whenever an ad gets successfully fetched, the delegate method “bannerViewDidLoadAd” will be implemented.

Congratulations! Now You Can Submit Your App in The App Store

After following the aforementioned steps, your application is ready to be launched publicly. Submit it in the App store and wait for the approval.

Note: If you want to discontinue showcasing the ads in your application, you will need to submit a fresh app without including the iAd framework.

With this tutorial, you can efficiently integrate banner ads in your application. The efforts and time that would be consumed while monetizing your application will offer you lucrative results.

#Apple#iPhone#Make money
Posted inMobiles

Spread the Word!

Avatar for Emily Heming

Emily Heming

Emily Heming is a savvy writer for xicom.biz, a leading iPhone Apps Development Company, where you can find some of the highly skilled and experienced iPhone application developers for hire.

Related articles

Reviews

Commander One 2.0: Advanced File Manager for Mac with Exciting New Features

Update Version of Commander One
News

WhatsApp for iPhone Now Allows Users to Send Group Messages Using Siri

Now you can send group messages in WhatsApp using Siri
Mobiles

8 Best Apps to Create Slow Motion Videos in iPhone and iPad

how to create slow motion videos in iPhone

Comments

  1. Avatar for Jack CalderJack Calder says

    January 2, 2019 at 3:28 PM

    Such good information provided by EMILY HEMING, As EMILY discussed Apple iOS serves the best medium for making money by monetizing application. I agree with these words.

    Reply

Comment Policy:

The comments section is aimed to help our readers in case of any questions or you can even appreciate us for our hard work. Every comment is strictly moderated before approving it.

Your name and comment will be visible to the public. Never share your personal information in the comments section.

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Over 1,30,286+ Followers

Join to get latest updates from Geek Dashboard

Facebook Twitter Telegram Pinterest YouTube Instagram

Recently Published

  1. Samsung Galaxy F13 Launched with Triple Rear Cameras and 6000mAh Battery in India

  2. Infinix InBook X1 Slim with 14-inch IPS Display and 10th Intel Core Processors Launched in India

  3. HP Spectre x360 Series Laptops Launched with 12th Gen Intel Processors in India

  4. Realme V20 5G Launched with MediaTek Dimensity 700 Chipset and a 5000mAh Battery

  5. New Dell XPS 13 and XPS 13 2-in-1 Launched with a Complete Redesign Starting at $999

Geek Dashboard Placeholder

Download the apps and never miss a story from us

We put a lot effort and resources in writing our articles and we believe it is our responsibility to satisfy your tech hunger. We will keep you filled forever!

  • Get Geek Dashboard App from Google Play
  • Get Geek Dashboard App from Chrome Web Store
Advertisement
Geek Dashboard Logo

Geek Dashboard, a technology blog strives to produce high-quality tech for our readers. Here you will find the latest updates on trending tech news, unbiased product reviews, and how-to guides on various gadgets.

Got a Tip? Write In tip@geekdashboard.com

© 2012 - 2022 · Geek Dashboard, product of ikva eSolutions

Blog Advertise About Jobs Contact Privacy Policy Write For Us T&C Office Setup

No dogs were injured while working on this website because we love them