Öppna konsolen

Get started with Google Analytics





Before you begin

  1. If you're creating a new project, Add Firebase to your iOS project and follow the steps to set up Google Analytics for your project during project creation.

    If you have an existing project and did not configure Google Analytics, you can link Google Analytics to your project from the Integrations tab of your settings > Project settings.


Add the Analytics SDK to your app

  1. Add the dependency for Firebase to your Podfile:
    pod 'Firebase/Analytics'
  3. Import the Firebase module in your UIApplicationDelegate:


    import Firebase


    @import Firebase;


    // Use Firebase library to configure APIs


    // Use Firebase library to configure APIs
    [FIRApp configure];

Start logging events





Analytics.logEvent(AnalyticsEventSelectContent, parameters: [
  AnalyticsParameterItemID: "id-\(title!)",
  AnalyticsParameterItemName: title!,
  AnalyticsParameterContentType: "cont"


[FIRAnalytics logEventWithName:kFIREventSelectContent


  2. Select Run from the left menu.
  3. Select the Arguments tab.

Next steps