YouTube Playables SDK - Getting started

YouTube Playables SDK is a web SDK for connecting web games with the YouTube environment. The SDK features a robust API to support games in a variety of ways to create an excellent gaming experience on YouTube.

  1. Add the SDK
  2. Integrate
  3. Test

Add the Playables SDK to your game

A game should have an index.html file in the root directory. Import the YouTube Playables SDK by adding this line before any of your game code:

<script src="https://www.youtube.com/game_api/v1"></script>

Integrate with Playables SDK

There are several required and optional integrations with the Playables SDK.

Required integrations

Review the publishing requirements overall, with a focus on integration requirements. Review the Playables SDK reference for implementation details.

Examples include:

In addition to the required integrations, several other functions are available to create a highly engaging experience. Examples include:

Review the Playables SDK reference for implementation details and additional functions.

TypeScript type definitions

For games using TypeScript, download type definitions.

Sample games

Samples are available that demonstrate how to integrate with YouTube Playables SDK, including plain JavaScript, Flutter web, Godot, and Unity.

Test your game with the test suite

Once you are ready, you can validate your integration using the test suite. To learn how, follow the test suite guide.

Test suite guide