How to Put Images Side by Side in WordPress (3 Block Methods)

Two landscape photos aligned side by side on a blue design desk

To put two images side by side in WordPress, add a Gallery block, upload or select both images and set Columns to 2. Use a Columns block instead if each image needs its own caption or text and should stack on phones, or a Row block if you want two images at a fixed size next to each other.

I built all three on the same page in WordPress 7.1.3 with the Twenty Twenty-Five theme, then checked them at desktop and phone widths.

MethodBest forOn a phone (375px wide)
Gallery blockTwo or more photos of equal importanceStays side by side
Columns blockImages with their own captions, text or buttonsStacks, one image under the other (can be turned off)
Row blockTwo images at a set width, such as logos or before and afterStays side by side and shrinks

Method 1: Use the Gallery Block

The Gallery block is the quickest way to line up photos, and it keeps them the same height.

Step 1: Add a Gallery Block

In the post or page editor, click the + inserter and choose Gallery. Click Media Library, select both images, then click Create a new gallery and Insert gallery. If the images aren’t on your site yet, click Upload instead and pick both files from your computer; they go straight into the Gallery.

Step 2: Set Columns to 2

With the Gallery selected, open the settings (gear) tab in the block sidebar and set Columns to 2. Leave Crop images to fit on so both images get the same height, even if one is taller.

WordPress Gallery block with two images side by side and Columns set to 2 in the block settings
A Gallery with Columns set to 2. The setting is under the gear tab in WordPress 7.1.

Add more images and raise Columns to show three or four in a row. On phones, the Gallery keeps the images side by side, so they become smaller. WordPress explains every option in its Gallery block documentation.

Method 2: Use the Columns Block

Use Columns when each image needs a caption, a paragraph or a button underneath it.

Step 1: Add a Two-Column Block

Click the + inserter, choose Columns and pick the 50 / 50 layout. See the Columns block documentation for the other layouts.

Step 2: Add an Image to Each Column

Click the + inside each column, choose Image and select your picture. You can add a caption or more blocks under each image.

WordPress Columns block with two images and the Stack on mobile setting turned on
Two images in a Columns block. Stack on mobile is on by default.

Two details show up in this screenshot. First, images with different shapes end up different heights, so crop them to the same aspect ratio (select the image, then the crop icon in its toolbar) if you want a tidy row. Second, Stack on mobile is on by default, which puts the images one above the other on phones. Turn it off if you want them side by side on small screens too.

Method 3: Use the Row Block

A Row arranges blocks horizontally, which suits two images at a fixed size.

Click the + inserter, choose Row, then add an Image block inside it, and a second Image block next to the first. Select each image and give both the same width in the block settings so the pair looks even. By default, the Row centers the images vertically.

WordPress Row block holding two images side by side with Row selected in the block sidebar
Two images inside a Row block. The Row keeps them on one line.

A Row doesn’t stack on phones. On my test page, both images stayed on one line and shrank to fit a 375px screen.

How the Methods Look on a Phone

Here’s the same page on a 375px-wide screen. The Gallery keeps the two images side by side, while the Columns block stacks them. The Row isn’t in this screenshot, but it also kept both images on one line:

Phone view of a WordPress page with a Gallery showing two images side by side and a Columns block stacking them
On a phone, the Gallery stays side by side and the Columns block stacks.

Small images side by side can be hard to see on phones. If the details matter, let them stack. For long, image-heavy posts, my guide to creating long-form content in WordPress covers how to pace images through the article.

Fix Common Side-by-Side Image Problems

ProblemFix
One image is taller than the otherIn a Gallery, turn on Crop images to fit. In Columns or a Row, crop both images to the same aspect ratio.
The images sit on top of each otherIn Columns, check that each image is in its own column. If they stack only on phones, turn off Stack on mobile. In a Row, check that both Image blocks are inside the same Row.
There’s a big gap between the imagesSelect the Gallery, Columns or Row block, open the Styles tab and change Block spacing under Dimensions.
The images are blurryUpload larger originals, or choose a bigger image size in the block settings.

Frequently Asked Questions

How do I put two images side by side in the Classic Editor?

Insert both images into the same paragraph with no line break between them, at a size small enough for both to fit across your content area. If the second image still drops below, set both to Align left. How this looks depends on your theme and it often stacks on phones, so switching the post to the block editor and using a Gallery or Columns block is more reliable.

How do I put an image next to text instead?

Use the Media & Text block. It places an image on one side and text on the other, and its Stack on mobile setting, which is on by default, puts the image above the text on phones.

Can I add more than two images in a row?

Yes. In a Gallery, add more images and raise Columns. In a Columns block, choose a layout with more columns.

Do side-by-side images slow down my page?

Not on their own, but every image adds weight. Compress large photos before you upload them, and use descriptive alt text for each image. For the rest of your on-page basics, see this on-page SEO checklist.

If you want the same images in a carousel instead, see how to add a Slick slider without a plugin. For pages you design outside the editor, see uploading an HTML file to WordPress.

And if what you need is rows and columns of text or numbers, like a comparison or a price list, use a table instead. Here’s how to create a table in WordPress without a plugin.

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Subscribe to our Monthly Newsletter

Get monthly updates of WordPress tips, tricks, and tutorials in your email.

Thanks. You have successfully subscribed.