Skip to content
charmotion
For iOS apps

An animated mascot for your iOS app, with SwiftUI code.

One image in; out comes a Rive file your SwiftUI views drive with a mood number and triggers, ready-made SwiftUI files for the legacy and new Apple runtimes, transparent HEVC MOV for AVFoundation, Keynote and Final Cut, and a launch animation for your first screen.

Code
SwiftUI — legacy + new Apple runtime
Files
.riv, HEVC-alpha MOV, MP4, GIF
Splash
LaunchStateMachine: intro → idle
Plan
Studio, $29/month
Rivet, a Charmotion demo character Live Rive file
Loops
Play once

This is the actual .riv our engine delivers, playing in your browser — the same state machine you drive from your app with one number input and a trigger per one-shot.

How do I add an animated mascot to SwiftUI?

Add the Rive Swift package, put the mascot's .riv in your bundle, and show it with RiveViewModel(fileName:stateMachineName:).view(). Set a number input such as mood to switch loops and fire triggers for one-shots, or use the new Apple runtime with Data Binding. Charmotion sets ship with ready SwiftUI files for both runtimes.

Animated Onboarding Mascot in SwiftUI

SwiftUI, ready to paste

import SwiftUI
import RiveRuntime   // Swift Package: rive-app/rive-ios

struct MascotView: View {
    @StateObject var mascot = RiveViewModel(
        fileName: "mascot",                       // mascot.riv in your bundle
        stateMachineName: "CharacterStateMachine"
    )
    var mood: Double = 0                          // 0 idle · 1 happy · 2 wave …

    var body: some View {
        mascot.view()
            .aspectRatio(1, contentMode: .fit)
            .onAppear { mascot.setInput("mood", value: mood) }
            .onChange(of: mood) { _, new in mascot.setInput("mood", value: new) }
    }

    func play(_ reaction: String) { mascot.triggerInput(reaction) }  // "success"
}

Shortened from the delivered file, which names the view, mood enum and reactions after your character.

Both Apple runtimes

{Name}View.swift uses the legacy RiveViewModel with state machine inputs. {Name}NewRuntimeView.swift uses the new async runtime with Data Binding through the Character view model.

Launch screen

A separate LaunchStateMachine plays the 2.6 s intro once and settles on idle — show it on your first screen after the static launch screen. It fires no completion event, so time the hand-off to the intro length.

Respect Reduce Motion

Check accessibilityReduceMotion and keep the mascot on idle (or a still poster) for people who ask for less motion.

Real output

Delivered files, exactly as you'd download them.

MP4 All plans

1080 × 1080 at 60 fps. Here: Pip’s wave, straight from the delivered file.

Transparent WebM & MOV Studio

Alpha channel included — the checkerboard shows through. MOV is HEVC with alpha for Apple apps and editors.

Rivet thinking — GIF output

GIF All plans

Light previews for docs, email and chat. Rivet’s “thinking” loop.

9:16 launch video All plans

1080 × 1920 for stories and splash screens. Bolt’s launch intro.

pip.riv · 40 KB

CharacterStateMachine
number input mood
0–9: idle, happy, wave, thinking, sad, loading, listening, talking, sleeping, attention
triggers: success · error · yes · no · enter · exit
LaunchStateMachine
launch → idle, plays once

Rive state machine Studio

One tiny vector file instead of 17 videos. It’s what powers the demo at the top of this page.

import { useRive, useStateMachineInput } from "@rive-app/react-canvas";

export function Pip({ mood = 0 }) {
  const { rive, RiveComponent } = useRive({
    src: "/pip.riv",
    stateMachine: "CharacterStateMachine",
    autoplay: true,
  });
  const input = useStateMachineInput(rive, "CharacterStateMachine", "mood");
  if (input) input.value = mood; // 0 idle · 1 happy · 2 wave · 3 thinking · 4 sad · 5 loading …
  return <RiveComponent style={{ width: 320, height: 320 }} />;
}

Paste-ready code Studio

Web, React and SwiftUI components named after your character.

Formats included per plan
FormatSpecsStarterStudio & Expert
MP41080 × 1080, 60 fps, all 17 animationsIncludedIncluded
9:16 launch video1080 × 1920 MP4IncludedIncluded
GIF480 px previewsIncludedIncluded
Rive (.riv)Vector; Data Binding view model + legacy inputs: mood for loops, triggers for one-shots, launch machineNot includedIncluded
Transparent WebMVP9 with alpha, 1080 × 1080Not includedIncluded
Transparent MOVHEVC with alpha (ProRes 4444 on request)Not includedIncluded
CodeWeb (HTML), React and SwiftUI componentsNot includedIncluded
Download all (.zip)Everything in one archive (MOVs separate)IncludedIncluded
Plans

Pick the formats you need.

SwiftUI code, the .riv and HEVC-alpha MOV are in Studio ($29/month). Starter ($4.99/month) has MP4, GIF and the 9:16 video. Prices in USD; tax is calculated at checkout by Polar.

Starter

MP4

$4.99/month

Video files for apps, socials and decks.

  • 2 character sets per month
  • 8 AI character designs per month
  • MP4 (1080×1080) for all 17 animations
  • GIF previews
  • 9:16 launch video
  • Use-cases: app mascot + launch/splash

Studio

All formats

Most complete

$29/month

The full interactive set for product teams.

  • 3 character sets per month
  • 12 AI character designs per month
  • Rive .riv with state machine
  • Transparent WebM + MOV (HEVC with alpha)
  • MP4, GIF and 9:16 launch video
  • Ready-to-paste web, React and SwiftUI code

Done with an expert

Hand-finished

$499one-time

An animator polishes your set with you.

  • 1 hand-finished character set
  • Everything in Studio
  • 4 AI character designs
  • All add-ons included when available
  • Private ticket thread with the animator
  • 2 revision rounds
FAQ

Before you start.

More in the full FAQ.

Do I get App Store preview videos too?

You get every animation as 1080 × 1080 MP4 plus a 1080 × 1920 launch video. App Previews must match Apple's exact device resolutions and show real app footage, so use these clips inside a screen recording of your app rather than as the preview itself.

Can I use the mascot without adding the Rive SDK?

Yes. Use the transparent HEVC MOV with AVPlayer, or the MP4 and GIF files. You lose live state switching, but every animation is there as a file.

Can I use the delivered .riv in a UIKit app?

Yes. The same .riv plays in UIKit through RiveViewModel's view or RiveView; the delivered code is SwiftUI, and the state machine names and inputs are identical.

Can the mascot appear in a widget or Live Activity?

Widgets and Live Activities can't run continuous animation, so use a still poster or a short transition there and keep the live Rive mascot inside the app.

See it with your character first.

Free, in your browser — nothing is uploaded until you choose a plan.

Try it free