This project is not covered by Drupal’s security advisory policy.

Media oEmbed TikTok

Media oEmbed TikTok adds TikTok as an oEmbed source for Drupal Media. It uses Drupal's oEmbed system, like the Media sources provided by core for YouTube and Vimeo.

The module provides the TikTok source and two formatters. It does not create a Media type for you. A site builder must create a Media type that uses the TikTok source.

Requirements

Drupal 11 / 12 and core media and image module enabled.

Create a TikTok Media type

Go to Structure → Media types → Add media type.
Select the TikTok source.
Let Drupal create the source field for the Media type.
On the display settings for this source field, select either TikTok embed or TikTok player.
Use canonical TikTok video URLs, for example https://www.tiktok.com/@user/video/. Short vm.tiktok.com share links are also supported when TikTok redirects them to a canonical video URL.

Formatters

TikTok embed

The TikTok embed formatter renders the TikTok embed markup returned by the oEmbed endpoint. Choose this formatter when you want the normal TikTok embed.

You can optionally show the cached TikTok thumbnail before the embed. You can select an image style for this thumbnail. You can also hide the embed until a visitor activates the thumbnail.

TikTok player

The TikTok player formatter renders TikTok's Embed Player v1. Its settings control the player options documented by TikTok, such as controls, progress bar, play button, volume control, autoplay, looping, music information, and video description.

This module adds one display option to this player: Constrain player to 9:16 video ratio.

This option uses CSS to center the output and constrain it to a 9:16 video area. It prevents the player's stretched, blurred background from being visible.

By default, TikTok's player will not work for a visitor who has disabled tracking. This is the default behavior of the TikTok player.

Similar modules

Video Embed TikTok uses the video_embed_field module instead of core oEmbed functionality.

Supporting organizations: 

Project information

Releases