Skip to content
Jetpack

Individual products

Security
VaultPress Backup Scan Akismet Anti-spam
Performance
Site Search Boost VideoPress
Growth
Stats Social Newsletter SEO Blaze CRM
Management
Manage Mobile App

Product Bundles

Pro Security, performance, and growth tools for your WordPress site. Complete The full Jetpack suite with higher service limits.
Pricing
Overview What Jetpack AI does for your site Skills WordPress superpowers for your agent Docs Connect and set up your AI agent Getting started Connect ChatGPT, Claude or a coding agent Compare Jetpack vs other WordPress MCP connectors

Connect your agent. It’s free.

Connect ChatGPT or Claude and let it run your site, with no paid plan needed.

Get it for ChatGPT (opens in a new tab) Or use Claude (opens in a new tab)
Support Guides and help from our team Docs How-to guides for every Jetpack feature Feature Requests Request features and vote on ideas Blog News, product updates, and how-tos
About
Sign in Get Started
Security
VaultPress Backup Scan Akismet Anti-spam
Performance
Site Search Boost VideoPress
Growth
Stats Social Newsletter SEO Blaze CRM
Management
Manage Mobile App

Product Bundles

Pro Complete
Pricing
Overview What Jetpack AI does for your site Skills WordPress superpowers for your agent Docs Connect and set up your AI agent Getting started Connect ChatGPT, Claude or a coding agent Compare Jetpack vs other WordPress MCP connectors

Connect your agent. It’s free.

Connect ChatGPT or Claude and let it run your site, with no paid plan needed.

Get it for ChatGPT (opens in a new tab) Or use Claude (opens in a new tab)
Support Guides and help from our team Docs How-to guides for every Jetpack feature Feature Requests Request features and vote on ideas Blog News, product updates, and how-tos
About Search
Sign in Get Started

Blog / Jetpack 101

How to Embed a YouTube Video in WordPress (Block Editor, Classic, & Plugins)

Jen Swisher's avatar

Jen Swisher December 2, 2025 · 7 min read


On this page

  1. TL;DR
  2. 1. Embedding a YouTube video with the YouTube Embed block
  3. 2. Embedding a YouTube video with a URL
  4. 3. Embedding a YouTube video in the Classic Editor
  5. 4. Embedding a YouTube video with the iframe embed code
  6. 5. Embedding a YouTube video in sidebars
  7. 6. Embedding a YouTube video with a plugin
  8. Common YouTube embedding problems and how to fix them
  9. A faster, cleaner way to host videos on WordPress
  10. Frequently asked questions

7 min read

Embedding YouTube videos into your WordPress site is one of the simplest ways to add engaging content, and it only takes a few minutes!

This guide covers several ways to add a YouTube video to your WordPress site, whether you want quick and easy or more advanced control. It also includes customization tips, plugin options, and common fixes if something goes wrong.

TL;DR

  1. Use the YouTube block or paste the public YouTube URL into the block editor for the simplest embed.
  2. Use iframe embed code in a Custom HTML block when you need parameters or more control.
  3. Use the Classic Editor Text tab if you are working outside the block editor.
  4. Choose privacy-enhanced embedding when visitor tracking concerns matter.
  5. Add title, intro text, captions, transcript, or summary when the video contains important information.
  6. Check responsive display on mobile and tablet before publishing.
  7. Avoid adding many autoplaying or heavy embeds to one page.
  8. Use VideoPress or another video host when you need more control over branding, privacy, or playback.

1. Embedding a YouTube video with the YouTube Embed block

If you’re using the WordPress block editor, the YouTube Embed block allows you to quickly add a video to a page or post. Simply follow these steps:

  1. Copy the URL of your YouTube video.
  2. In your post or page, click the plus (+) sign to add a new block.
  3. Type “YouTube” in the block search bar.
  4. Drag the YouTube Embed block into your desired location on the page.
  5. Paste your video link into the field.
  6. Click Embed.
adding a YouTube Embed URL block

The video will appear directly in the editor. You can align it, resize the block, or add a caption if needed.

2. Embedding a YouTube video with a URL

WordPress supports automatic embeds using oEmbed, so you can paste a YouTube URL on its own line, and WordPress will turn it into a video automatically. To do this:

  1. Copy the video URL from YouTube.
  2. Go to your WordPress dashboard. In the page or post you’re working on, paste the URL on a new line.
  3. WordPress will detect it and convert it to a video player.
embedding a video using the URL

This method is fast and doesn’t require any extra setup on your end.

3. Embedding a YouTube video in the Classic Editor

If you’re still using the Classic Editor, embedding simply requires pasting the video link. Follow these steps:

  1. Copy the YouTube video URL.
  2. In the Classic Editor in WordPress, make sure you’re in the Visual tab (not Text).
  3. Paste the link on a blank line.
  4. Save or update the post.
embedding a YouTube video in the Classic Editor

When you view the page, the embedded video will appear where you placed the link.

4. Embedding a YouTube video with the iframe embed code

If you want more control over how your video appears, try using the embed code from YouTube. Just follow these steps:

  1. On the YouTube video, click Share.
  2. Choose Embed, then copy the iframe code.
  3. In WordPress, add a Custom HTML block or widget to the page.
  4. Paste the iframe code into the block.
  5. Save or publish your page.
using the Custom HTMl block to add a video embed code

This method is great for advanced layout or design needs. If you’re familiar with basic coding principles, you can customize the iframe code by adding: 

  • autoplay=1 to start the video automatically
  • rel=0 to hide related videos at the end
  • controls=0 to hide playback controls
  • mute=1 to start the video with no sound

Example:

Replace VIDEO_ID with the actual ID from your YouTube link.

5. Embedding a YouTube video in sidebars

Want to show a YouTube video in your sidebar or footer? If you’re using a block theme, simply:

  1. Navigate to Appearance → Editor in the WordPress dashboard.
  2. Open the Patterns tab, then choose the pattern or template part you want to edit (e.g. the footer).
  3. With the footer open, click the + icon at the top left to open the Block Inserter. Search for “YouTube” and add the YouTube Embed block where you’d like in the footer.
  4. Paste the YouTube video link into the block and click Embed.
  5. The video will appear in the Site Editor. Now, click Save to save your changes.
adding a video to the footer

If you’re using a classic theme, follow these steps:

  1. On the YouTube video, click Share.
  2. Choose Embed, then copy the iframe code.
  3. Go to Appearance → Widgets in your WordPress dashboard.
  4. Expand the widget area where you want to add your video.
  5. Drag the Custom HTML widget into place.
  6. Add the iframe code you copied earlier and click Save.
adding a video embed code to a widget

6. Embedding a YouTube video with a plugin

Plugins give you more options for things like displaying video galleries and adding lightboxes. Here are a few you can choose from:

  • Embed Plus for YouTube: Embed and customize playlists, channels, livestreams, and more.
  • Smash Balloon YouTube Feed: Show playlists, channels, or video grids and customize everything from video end actions to button displays.

Common YouTube embedding problems and how to fix them

Most of the time, embedding works without problems. But here are some potential problems and ways to fix them quickly:

The video doesn’t appear:

  1. Make sure the URL is not inside a block that changes formatting (like a Quote block).
  2. Place the URL on its own line with no other text.
  3. Try previewing in a different browser or clear your cache.

The video doesn’t resize on mobile:

  • Use the YouTube block or plugins that make videos responsive.
  • If using iframe code, wrap it in a container with CSS like max-width: 100%.

The playback starts with sound on:

  • Add mute=1 to the embed code if you want autoplay without sound.
  • Try a different browser. Most browsers will block autoplay with sound by default.

A faster, cleaner way to host videos on WordPress

YouTube is a great place to share and discover videos, but it’s not always the best fit for every site. If you want more control over how your videos are displayed, how quickly they load, or what shows up at the end, consider a dedicated video hosting solution like Jetpack VideoPress.

Jetpack VideoPress is built for WordPress, so you can upload and manage your videos directly from your dashboard. It gives you a fast, reliable player without third-party branding or distracting ads. Your visitors see your content, and nothing else.

Here’s what makes Jetpack VideoPress a smart choice:

  • Fast load times: Videos are delivered through a global content delivery network (CDN) and stored separately from your site, so every page loads quickly.
  • A clean player: There are no third-party logos, suggested competitor videos, or platform clutter — just your video, styled to match your site.
  • Responsive design: The player adapts automatically to screen sizes, so your videos look great on phones, tablets, and desktops.
  • Simple management: Upload videos from the WordPress editor or media library just like any other image or file.

If you’re publishing video content regularly and want more speed, control, and flexibility, VideoPress is an easy way to upgrade your setup without adding complexity.

You can learn more or get started here.

Frequently asked questions

Can I remove the YouTube logo and related videos from my embed?

You can’t remove all YouTube branding, but adding modestbranding=1 to your embed URL reduces how prominent the logo is. You also can’t fully disable related videos anymore, and the old rel=0 parameter no longer reliably limits them to your own channel. YouTube will still show related content at the end.

What is the difference between using the WordPress YouTube Block and an Iframe?

The WordPress YouTube Block is the easiest method for most users. It uses a system called oEmbed. You simply paste the URL, and WordPress automatically retrieves the video and formats it for you. It is simple but gives you fewer options for customization.

An iframe is a piece of HTML code that gives you manual control. You should use an iframe when you need to change specific settings that the Block does not support. For example, if you want to adjust the player controls, turn off the title display, or force specific height and width parameters, the iframe method is the better choice. It requires you to handle the code yourself but offers much more power.

Why does my YouTube embed say “Video unavailable” or “Refused to connect”?

This error message typically appears for one of three reasons. First, the owner of the video may have changed the privacy settings to “Private” or deleted the video entirely. If the source is gone, your embed cannot play it.

Second, the video owner might have disabled embedding for that specific video. Creators can choose to allow their video to play on YouTube but block it from playing on other websites.

Third, your own website security headers might be blocking the connection. If you have a strict “Referrer Policy” set up in your security plugin, it might prevent YouTube from validating the request. You should check your security settings if the video works fine on YouTube directly.

Does embedding YouTube videos help with SEO rankings?

Yes, embedding videos can improve your SEO rankings indirectly by increasing user engagement. When a visitor stops to watch a video on your page, they stay on your website longer. This metric is often called “dwell time.” Google interprets high dwell time as a sign that your content is valuable and helpful.

Like Loading…
Jen Swisher's avatar

Written by

Jen Swisher

Jen is a Customer Experience Specialist for Jetpack. She has been working with WordPress and Jetpack for over a decade. Before starting at Automattic, Jen helped small businesses, local non-profits, and Fortune 50 companies create engaging web experiences for their customers. She is passionate about teaching others how to create on the web without fear.

The Finest Video Hosting for WordPress

Stunning-quality video with none of the hassle. Drag and drop videos through the WordPress editor and keep the focus on your content, not the ads.

Get VideoPress

Questions about this post? Ask in the support forum

Share


Keep reading.

More from Jetpack 101, newest first.

See all posts

Jetpack 101 Mar 31, 2026

WordPress Image SEO: 12 Techniques to Rank Higher & Load Faster

Are images helping or hurting your rankings? What can you do about it? 12 realistic ways to optimize your image strategy for more high-quality traffic.

Jen Swisher's avatar Jen Swisher 14 min read

Jetpack 101 Mar 26, 2026

WordPress Site Redirecting to Spam? Here’s How to Fix a Hacked Site

Uncover hidden malware, remove malicious code, and stop spam redirects fast — before they damage your reputation. Secure your WordPress site.

Jen Swisher's avatar Jen Swisher 12 min read

Jetpack 101 Mar 24, 2026

WordPress Form with File Upload: How to Create One in 3 Steps

How to create a secure file upload form in WordPress — fast. Add drag-and-drop uploads in just 3 simple steps. Plus, the top tool to keep…

Jen Swisher's avatar Jen Swisher 5 min read

Run your WordPress site the AI-first way.

Free to start, and AI agents are free to connect. Money back within 14 days on yearly plans.

Get Started Get Jetpack free

WordPress Plugins

  • Akismet Anti-spam↗ (opens in a new tab)
  • Jetpack↗ (opens in a new tab)
  • Jetpack Boost↗ (opens in a new tab)
  • Jetpack CRM↗ (opens in a new tab)
  • Jetpack Protect↗ (opens in a new tab)
  • Jetpack Search↗ (opens in a new tab)
  • Jetpack Social↗ (opens in a new tab)
  • Jetpack VideoPress↗ (opens in a new tab)
  • VaultPress Backup↗ (opens in a new tab)
  • WP Super Cache↗ (opens in a new tab)
  • Download

AI

  • Jetpack AI
  • Skills
  • WordPress MCP

Partners

  • Partner Program
  • Recommended Hosts
  • For Hosts
  • For Agencies
  • For Affiliates

Developers

  • Documentation↗ (opens in a new tab)
  • Beta Program
  • Jetpack on GitHub↗ (opens in a new tab)

Help

  • Knowledge Base
  • Forums↗ (opens in a new tab)
  • Reviews and Testimonials
  • Contact Us
  • About Jetpack
  • Press
Select language English
  • English
  • Deutsch
  • Español
  • Français
  • 日本語

© 2026 Automattic Inc. All rights reserved.

  • Terms of Service↗ (opens in a new tab)
  • Privacy Policy↗ (opens in a new tab)
  • GDPR

Made with care by

Download on the App Store Get it on Google Play
Loading Comments...
  • Reblog
  • Subscribe Subscribed
    Jetpack
    Join 53,352 other subscribers

    Have a WordPress.com account? Log in now.

  • Jetpack
    Copy shortlinkView post in Reader
    Manage subscriptionsSign upLog in
    Report this content
    Collapse this bar
%d