Cloud Builds · TV
An Apple TV app is built like an iPhone app, with Xcode and App Store Connect, but driven by a remote. This guide starts with which framework to use. Then it builds, runs and ships the app with VibeView cloud builds from Windows, Linux or a Mac. Already have a TV project? Skip to the build.
Choose how to build your Apple TV app
| Route | tvOS support | Android TV from the same code | Best when |
|---|---|---|---|
| Swift + SwiftUI | Native, from Apple | No | You want native tvOS APIs, or you already have a SwiftUI iPhone app |
| React Native | Through the react-native-tvos fork | Yes | Your team writes JavaScript or TypeScript |
| Expo | Through the same fork, plus a config plugin | Yes | You already have an Expo phone app, or want Expo’s tooling |
| Flutter | None | Yes | Android TV only |
Whichever you choose, the build needs Xcode and the tvOS SDK. Apple ships both only as a Mac app: the Xcode listing on the Mac App Store includes the tvOS SDK and requires a Mac with Apple silicon. That’s the step VibeView moves to the cloud.
Native: Swift and SwiftUI
Apple’s tvOS developer page points to SwiftUI, including for bringing an iPhone or iPad app to tvOS. UIKit, AVKit and Metal work too. Create the project in Xcode with the tvOS App template, or add a tvOS target to an existing app. SwiftUI’s focus APIs, such as focusable, @FocusState, focusSection() and defaultFocus, control where the highlight goes.
Creating the project and using SwiftUI previews need Xcode on a Mac, where you can also build and run it locally. After that, you can edit Swift files on any machine and compile in the cloud. A native project without CocoaPods needs no Metro and no install step, so each profile is plain xcodebuild:
{
"defaultPlatform": "tvos",
"platforms": {
"tvos": {
"build": {
"profiles": {
"development": {
"command": "xcodebuild -project MyTVApp.xcodeproj -scheme MyTVApp -configuration Debug -sdk appletvsimulator -arch arm64 -derivedDataPath build CODE_SIGN_IDENTITY=-",
"artifact": "build/Build/Products/Debug-appletvsimulator/*.app"
},
"production": {
"command": "xcodebuild archive -project MyTVApp.xcodeproj -scheme MyTVApp -configuration Release -destination generic/platform=tvOS -archivePath build/MyTVApp.xcarchive CODE_SIGN_STYLE=Manual ${VIBEVIEW_DEVELOPMENT_TEAM:+\"DEVELOPMENT_TEAM=$VIBEVIEW_DEVELOPMENT_TEAM\"} ${VIBEVIEW_PROVISIONING_PROFILE:+\"PROVISIONING_PROFILE_SPECIFIER=$VIBEVIEW_PROVISIONING_PROFILE\"} ${VIBEVIEW_CODE_SIGN_IDENTITY:+\"CODE_SIGN_IDENTITY=$VIBEVIEW_CODE_SIGN_IDENTITY\"} && xcodebuild -exportArchive -archivePath build/MyTVApp.xcarchive -exportPath build -exportOptionsPlist \"$VIBEVIEW_EXPORT_OPTIONS_PLIST\"",
"artifact": "build/*.ipa"
}
}
}
}
}
}
The production profile is the archive and export pair from App Signing, pointed at tvOS. With no Pods or app extensions, the team, profile and identity can go on the archive command, so skip the manual-signing part of Step 3. If the project uses CocoaPods, run pod install first and build the .xcworkspace. Then sign as Step 3 describes: manual signing in the app target, and only the identity on the command line. TestFlight needs a new build number for every upload, so bump the build number in Xcode before each production build. Follow Steps 1 to 4 below with these profiles in place of the Expo ones.
React Native: react-native-tvos
Standard React Native doesn’t target Apple TV. react-native-tvos is the community fork that adds Apple TV and Android TV, published to npm under the same name. Its README lists tvOS 15.1 as the minimum. Start a new project from its TV template:
npx @react-native-community/cli@latest init MyTVApp --template @react-native-tvos/template-tv
The template’s own run command, npx react-native run-tvos, needs a Mac with Xcode. Without one, skip it and use the cloud build in Step 1. The fork adds TV APIs such as TVFocusGuideView, for Apple’s focus guides, and useTVEventHandler, for remote events. A testID becomes the element’s identifier on both TV platforms. With it, a VibeView test written for a cloud Apple TV runs on a cloud Android TV, and replay checks that focus lands on the same element (TV testing).
Expo: the same fork, with a config plugin
An Expo app reaches Apple TV through react-native-tvos too. Its react-native dependency points at the fork, and the @react-native-tvos/config-tv plugin turns expo prebuild into a tvOS project when EXPO_TV=1 is set, as Expo’s TV guide describes. Build an Expo app for Apple TV and Android TV covers the whole setup, with the TV app beside your phone app. The build commands below include the Expo version.
Flutter: no Apple TV
Flutter’s supported platforms don’t include tvOS, and the request for it has been open since 2019. Community engine forks exist, but they cover only some Flutter versions. For Apple TV, pick SwiftUI, React Native or Expo. Flutter still targets Android TV: VibeView cloud builds the app, and it runs on VibeView’s 64-bit Android TV devices (Cloud Builds has the Flutter notes).
What every Apple TV app has to get right
Apple TV apps run on focus. Nobody taps the screen: the remote moves a highlight from item to item, and the select button acts on whatever holds it. Apple’s tvOS design guidelines ask apps to work with that focus system. They also ask for text that reads from across the room, since viewers sit “often 8 feet or more” away.
So check three things on every screen. Focus starts somewhere sensible. Every item can be reached with the arrow buttons. Back returns focus to where you came from. The cloud Apple TV in Step 2 is enough to check all three, and Testing tvOS focus navigation shows how.
Build the Apple TV app without a Mac
A tvOS app has every Mac dependency an iPhone app has: Xcode, the Apple TV simulator, a distribution certificate in a keychain, and its own provisioning profile. The steps below replace each one, taking a React Native or Expo TV project from source to TestFlight. For a native Xcode project, use the profiles from the SwiftUI section. If you’d rather watch it happen, a coding agent did this whole flow in 46 minutes: An AI agent shipped an Apple TV and Android TV app.
What you need
- A VibeView account and the CLI:
npm install -g vibeview && vibeview login - A tvOS project: native Xcode, react-native-tvos (bare), or Expo with the
@react-native-tvos/config-tvplugin - For TestFlight: an Apple Developer account, an App Store Connect API key, and the app record created in App Store Connect with tvOS as its platform
Cloud builds use your plan’s monthly build minutes, then usage credit. See pricing.
Step 1: a tvOS simulator build
TV schemes vary too much to guess (older bare templates use a separate MyApp-tvOS scheme), so you write the tvOS build command once and vibeview.json keeps it. For an Expo project with config-tv, where prebuild generates the TV project when EXPO_TV is set:
{
"defaultPlatform": "tvos",
"platforms": {
"tvos": {
"build": {
"env": { "EXPO_TV": "1" },
"profiles": {
"development": {
"command": "npm ci && npx expo prebuild --platform ios && xcodebuild -workspace ios/MyApp.xcworkspace -scheme MyApp -configuration Debug -sdk appletvsimulator -derivedDataPath ios/build CODE_SIGN_IDENTITY=-",
"artifact": "ios/build/Build/Products/Debug-appletvsimulator/*.app"
}
}
}
}
}
}
The env map sits beside profiles, so every build of the platform gets it. For a bare react-native-tvos project, drop the prebuild leg and use your own workspace and TV scheme. Either way the important parts are -sdk appletvsimulator and an artifact path under Debug-appletvsimulator. Then:
vibeview build --cloud --platform tvos
The CLI uploads your source, without node_modules or ios/Pods, and streams the Xcode log. The first succeeded build creates the app in VibeView from the binary and saves its appId to vibeview.json.
Step 2: run it on a cloud Apple TV
Run vibeview dev --platform tvos. It opens the build on a cloud Apple TV, connected to Metro on your computer, with Fast Refresh. A native SwiftUI build has no Metro: open the build’s page and choose Run this build. A React Native or Expo build needs Metro. To share it or open it with Run this build, add a preview profile: the same command in -configuration Release, with an artifact under Release-appletvsimulator. Build it with vibeview build --cloud --platform tvos --profile preview. The app opens on an Apple TV simulator in your browser, where your arrow keys move the d-pad and Enter selects. This is where you run the three focus checks from above.
Step 3: a signed tvOS build
A production build signs a tvOS .ipa for the App Store. It can’t run on a simulator, so it appears on the Builds page with a Download action rather than in Build history.
-
Connect your Apple account once. In App Store Connect under Users and Access → Integrations, create a team API key with the App Manager or Admin role and download the
.p8file. Store it:vibeview credentials asc-key add --key-id <KEY_ID> --issuer-id <ISSUER_ID> --file AuthKey_<KEY_ID>.p8 -
Generate the tvOS credential.
vibeview credentials generate --platform tvos --name tv-release --app <app-id>VibeView reuses the Apple Distribution certificate it already made for your team (for example, for your iOS app) or creates one, registers the bundle id if needed, and issues a tvOS App Store profile. Prefer your own files? Upload the same
.p12you use for iOS with your tvOS profile:vibeview credentials add --platform tvos --file cert.p12 --profile app-tvos.mobileprovision. -
Add the production profile. React Native TV projects use CocoaPods. A provisioning profile on the
xcodebuildcommand line reaches every Pod target and fails the archive. So set manual signing on the app target in the project (an Expo config plugin can do it; Marquee has one), and pass only the signing identity on the command line:{ "platforms": { "tvos": { "appId": "my-tv-app-abc123", "build": { "env": { "EXPO_TV": "1" }, "profiles": { "development": { "command": "...", "artifact": "ios/build/Build/Products/Debug-appletvsimulator/*.app" }, "production": { "command": "npm ci && npx expo prebuild --platform ios && xcodebuild archive -workspace ios/MyApp.xcworkspace -scheme MyApp -configuration Release -destination generic/platform=tvOS -archivePath ios/build/MyApp.xcarchive ${VIBEVIEW_CODE_SIGN_IDENTITY:+\"CODE_SIGN_IDENTITY=$VIBEVIEW_CODE_SIGN_IDENTITY\"} && xcodebuild -exportArchive -archivePath ios/build/MyApp.xcarchive -exportPath ios/build -exportOptionsPlist \"$VIBEVIEW_EXPORT_OPTIONS_PLIST\"", "artifact": "ios/build/*.ipa", "autoIncrement": true } } } } } }VibeView writes the export options file from your profile during the build; you never author it. App Signing explains every part of this command.
-
Build.
vibeview build --cloud --profile production --platform tvosWith
autoIncrementon, each production build gets the next build number asVIBEVIEW_BUILD_NUMBER; wire it into your app config once (Cloud Builds: build numbers). The first number usually starts above the highest build already in App Store Connect.
Step 4: upload the Apple TV app to TestFlight
Create the app record in App Store Connect first (My Apps → + → New App, platform tvOS, your bundle id). Apple only accepts uploads for apps that exist there. Then check and submit:
vibeview submit --check --platform tvos --bundle-id com.example.mytvapp
vibeview submit --platform tvos --latest
The CLI streams the upload and exits once Apple accepts it; VibeView then follows the build through Apple’s processing. Add --group "QA team" --what-to-test "…" to send the build to a TestFlight group, and --wait-distribution to wait until it reaches your testers. App Store review, the listing and screenshots stay in App Store Connect.
The same project on Android TV
The Android half of a react-native-tvos project builds with --platform androidtv. A debug build runs on a cloud Android TV emulator; keep both x86 and x86_64 native code in it so it runs on every Android TV device.
{
"platforms": {
"androidtv": {
"build": {
"env": { "EXPO_TV": "1" },
"profiles": {
"development": {
"command": "npm ci && npx expo prebuild --platform android --no-install && cd android && ./gradlew assembleDebug",
"artifact": "android/app/build/outputs/apk/debug/*.apk"
},
"production": {
"command": "npm ci && npx expo prebuild --platform android --no-install && cd android && ./gradlew bundleRelease",
"artifact": "android/app/build/outputs/bundle/release/*.aab"
}
}
}
}
}
}
Android TV needs no credential of its own: production builds sign with your Android keystore, so vibeview credentials generate --platform android --name release covers phone and TV. Add the guarded Gradle signing block from App Signing, then:
vibeview build --cloud --profile production --platform androidtv
vibeview submit --platform androidtv --latest --track internal
For Fire TV, the same Android TV app goes to the Amazon Appstore with --store amazon, from a signed .apk build (Amazon Appstore has the profile).
vibeview build --cloud --platform all builds every configured platform at once, so Apple TV and Android TV come out of one command. The Android cloud build guide covers the Play service account setup.
Roku is the exception. A Roku channel has no compile step and can’t be cloud-built: package the channel .zip and upload it with vibeview build --platform roku (without --cloud). See Test a Roku channel in your browser.
Troubleshooting
- The tvOS archive fails with “does not support provisioning profiles”. A profile on the command line reached a target that can’t take it (a Pod, a Swift package or an app extension). Move manual signing into the app target and keep only
CODE_SIGN_IDENTITYon the archive command. - “Apple doesn’t know this app yet”. The App Store Connect record is missing, was created for iOS instead of tvOS, or uses a different bundle id.
vibeview submit --checkcatches this before you build. - Apple refuses a duplicate build number. Turn on
autoIncrement, or seed the counter withvibeview versions set --app <app-id> --platform tvos <number>. - The Android TV build installs on some TV emulators but not others. The build is missing
x86orx86_64native code. (Flutter apps run only on the x86_64 devices.)
Frequently asked questions
What do I need to build an Apple TV app?
Xcode with the tvOS SDK, which runs only on a Mac, and a framework that targets tvOS: Swift and SwiftUI, React Native through react-native-tvos, or Expo with the same fork. VibeView cloud builds supply the Mac and Xcode, so the rest can happen on Windows or Linux.
Can Flutter build Apple TV apps?
Not officially. Flutter’s supported platforms don’t include tvOS, and community engine forks cover only some Flutter versions. Flutter does build Android TV apps.
Can I build a tvOS app without a Mac?
Yes. The build runs on VibeView’s macOS builders, the Apple TV simulator streams to your browser, the profile comes from Apple’s API through your App Store Connect key, and the TestFlight upload runs server-side. For React Native and Expo, nothing on your machine needs macOS. A SwiftUI project still needs a Mac once, to create it in Xcode.
Do I need a separate certificate for tvOS?
No. tvOS uses the same Apple Distribution certificate as iOS; only the provisioning profile differs. When you generate both, VibeView reuses the certificate and issues a second profile.
Can a VibeView Apple TV run my signed TestFlight build?
No. A signed App Store build only installs on physical hardware. Test the simulator build from Step 1 on the cloud Apple TV, and use TestFlight for the hardware pass.
Next steps
- Cloud Builds, App Signing, Store Submission and TV testing: the reference docs
- Cloud builds overview: iOS, Android, Apple TV and Android TV builds in one place
- Upload to TestFlight without a Mac: the iPhone version of Step 4
Related guides
In the documentation
Try it yourself
Open a live iOS simulator, Android emulator, Apple TV, Android TV or Roku in your browser.
Start free