WordPress.org

Plugin Directory

Embed YouTube Block – Fast Loading Videos, Shorts & Playlists

Embed YouTube Block – Fast Loading Videos, Shorts & Playlists

Descriere

The default embed block for YouTube videos sucks. It slows down your site. The more videos on the page the more it slow. This single-block plugin fixes that.

Why this block is better than the default one:

This plugin also provides a PHP API for developers to render a YouTube video URL as this block; or to automatically transform core/embed YouTube videos into this block.

The simplest example is:

    better_youtube_embed_block_render_block( ['url' => 'https://youtu.be/paSXmpHU9K4'] );

The example with all the parameters is:

    better_youtube_embed_block_render_block(
      [
        'url'               => 'https://youtu.be/paSXmpHU9K4',
        'aspectRatio'       => '16/9',
        'isMaxResThumbnail' => false,
        'thumbnailFormat'   => 'jpg',
        'caption'           => 'My awesome video',
        'caption_kses'      => false,
        'customThumbnail'   => 'https://example.com/bg.jpg',
        'settings'          => ['loop' => 1, 'rel' => 0],
        'echo'              => false,
      ]
    );

To automatically transform all core/embed YouTube videos on your site to this block, you need to put the following code to the wp-config.php file or your theme/plugin:

    define('BYEB_SPEED_UP_YOUTUBE_VIDEOS', true);

or

    add_filter( 'byeb_speed_up_youtube_videos', '__return_true' );

On iOS, browsers like Safari and Chrome require two clicks to play videos. If you want to allow users to play videos with a single click, you need to add the following code to the wp-config.php file or your theme/plugin:

    define('BYEB_FORCE_IFRAME_ON_UNSUPPORTED_BROWSERS', true);

Please check out this page to see how fast it helps. The page contains around 30 embedded YouTube videos but they don’t slow down the page.

If this plugin is useful for you, please do a quick review and rate it on WordPress.org to help us spread the word. I would very much appreciate it.

Please check out my other plugins if you’re interested:

The plugin is developed using @wordpress/create-block.

Capturi ecran

Blocuri

Acest modul oferă 1 bloc.

Embed YouTube Video Faster than the default YouTube embed. Supports videos, shorts and playlists.

Instalare

  1. Upload the plugin files to the /wp-content/plugins directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the ‘Plugins’ screen in WordPress

Întrebări frecvente

What problem does this plugin solve?

It provides a better solution to embed YouTube videos than the default one.

Who needs this plugin?

Anyone can use this plugin.

Recenzii

28 noiembrie 2025 1 răspuns
default embed block for YouTube videos sucks YouTube Block – A better way to embed YouTube videos, shorts, playlists – Cool plugin
17 august 2025 1 răspuns
Very easy to use and the php api function to add a block is great. I use it via a custom shortcode.
23 martie 2025 1 răspuns
This one is essential if you have YouTube videos on your block site. Super simple and effective.
4 martie 2025 1 răspuns
I’ve tried 10+ similar plugins to do similar things for youtube videos, but to put it simply, by far and large this was the best one.
26 noiembrie 2024 1 răspuns
Your plugin is a little gem. You’re a genius. Thanks a lot.
Citește toate cele 16 recenzii

Contributori și dezvoltatori

„Embed YouTube Block – Fast Loading Videos, Shorts & Playlists” este un software open-source. La acest modul au contribuit următoarele persoane.

Contributori

„Embed YouTube Block – Fast Loading Videos, Shorts & Playlists” a fost tradus în 3 locale. Mulțumim traducătorilor pentru contribuția lor.

Tradu „Embed YouTube Block – Fast Loading Videos, Shorts & Playlists” în limba ta.

Te interesează dezvoltarea?

Răsfoiește codul, vezi depozitarul SVN, sau abonează-te la jurnalul de dezvoltare prin RSS.

Istoric modificări

1.1.6

Release Date – 10 June 2026

1.1.5

Release Date – 06 May 2026

1.1.4

Release Date – 06 January 2026

1.1.3

Release Date – 21 July 2025

1.1.2

Release Date – 06 January 2025

1.1.1

Release Date – 09 November 2024

1.1.0

Release Date – 23 August 2024

1.0.5

Release Date – 15 June 2024

1.0.4

Release Date – 23 February 2024

1.0.3

Release Date – 05 January 2024

1.0.2

Release Date – 11 August 2023

1.0.1

Release Date – 21 April 2023

1.0.0

Meta

Evaluări

5 din 5 stele.

Contributori

Suport

Probleme rezolvate în ultimele două luni:

1 din 1

Vezi forumul pentru suport

Donează

Vrei să sprijini dezvoltarea acestui modul?

Donează pentru acest modul