Websites & Apps

{"type":"IMAGE"

DROPIDEA By Admin
May 31, 2025 2 views
DROPIDEA | دروب ايديا - {"type":"IMAGE"

Do you want to center the video in WordPress? When you add a video within your article or publication, this video will be aligned by default to the right side of the site page for sites written in Arabic, or along the left side for sites written in English or any other language, moving from left to right (Left to right).

If you want to upload a video clip to your site or want to embed a video clip from YouTube or Viemo and display it in an elegant way in the middle of the site pages, this article explains in detail how to align the video to the center in WordPress in different ways and with ease. The easiest way to center video on your site page Videos are one of the most popular forms of media in the world, and WordPress fully supports them.

So if you don't center the video clip, it may leave an empty space next to it. By default, the video clip will be aligned to the left (for the classic editor), while in the new WordPress editor

Gutenberg will automatically center videos for you. It's super easy to center videos in WordPress, and it only takes a minute of your time!

1- Center the video using the traditional editor in WordPress

To add a video using the classic editor in WordPress (for example, a video from YouTube), and then align the video to the center, you must do the following steps: First, you must choose the video you want to embed from YouTube by clicking on the Share link. Then you must choose (Embed) to get a link that enables you to embed the video on your site.

After the link appears as shown in the following image, click the Copy button to copy it to the clipboard. Then you need to go to the traditional WordPress editor, and choose the “Text” tab to switch to a code editor

HTML as shown in the following image: Then paste the previous code that you copied in the previous step here to add the video. After pasting the code, the video clip will appear as in the picture

Next it will be towards the right. To change the center alignment of a clip, you must...

Add the following simple HTML code before and after the video embed code. // Video embed code here When you preview the changes the video in the middle will be like this: You can now save the changes and preview the post or page.

You will notice that your video has been aligned precisely in the center of your content area. 2- Center the video using the Gutenberg editor In the new WordPress editor known as the Gutenberg editor, the video will be automatically centered, but if the video is not centered for some reason, you can align it to the center as follows: Click on the (+) sign.

To add a component, choose Video to add a custom component to the video. You will see several options to add the video (add a video from the media library, upload a new video, or add a video from a URL link) (to include a video from YouTube, Vimeo, etc..)

on your site). Read also:

Explanation of uploading downloadable files in WordPress

Select the option you want and add the video, and it will automatically be center-aligned (the component editor will often center-align the video automatically). If this does not happen, you can select the video clip and press the Align tool > then choose Center-align as shown in the following image.

When you preview the results, the video will be in the middle of the screen. These are the easy steps that we explained to center the video to display it during the content better and in a more elegant and streamlined way.

DROPIDEA

We hope this article has added real value to you. At DROPIDEA, we always strive to deliver high-quality content that helps you grow and evolve in the digital space. Follow us for more useful articles and guides.

Share Article