PDF reference

Replacing PDF images without breaking the layout

Swapping an image in a PDF is mechanically easy and visually easy to get wrong. The swap itself rarely moves anything — but a replacement with the wrong proportions, the wrong resolution or the wrong background arrives inside a frame that was measured for something else, and the result reads as an obvious edit even though nothing shifted.

Free — no signupNo watermarkNothing to installYour layout preserved

The short answer

A PDF draws an image by stretching it into a rectangle defined by a transformation matrix, so a replacement inherits the original’s frame regardless of its own proportions. Matching the original’s aspect ratio prevents distortion, matching or exceeding its pixel dimensions prevents softness, and using PNG preserves transparency.

The frame is fixed by a matrixAspect ratio mismatch causes stretchingEffective DPI = pixels ÷ frame sizePNG for transparency, JPG for photosText does not reflow around images

How a PDF actually places an image

What makes this predictable is understanding how a PDF places an image in the first place. It does not store the picture at a position and a size in the way a word processor does. It stores the pixels once, as an object, and then draws them into a unit square that a transformation matrix stretches into a rectangle on the page. The frame is fixed by that matrix, and your replacement will be stretched into it whatever shape it is.

The five properties that decide the result

The frame

Position and size come from a transformation matrix applied before the image is drawn, not from the image itself. Replacing the pixels leaves that matrix alone, which is precisely why a swap does not move anything on the page.

Aspect ratio

The frame has fixed proportions and your replacement is stretched to fill it. A 4:3 photo dropped into a 16:9 frame is not cropped, it is squashed. Match the original’s ratio and this problem disappears entirely.

Effective resolution

What matters is not the image’s DPI metadata but its pixel dimensions divided by the frame’s physical size. A 300-pixel-wide logo in a 2-inch frame prints at 150 DPI regardless of what the file claims.

Transparency

JPG has no alpha channel. A logo saved as JPG brings a white rectangle with it, which is the single most common reason a swapped logo looks wrong on a coloured or patterned background. PNG carries transparency.

Stacking order

Objects are drawn in the order they appear in the content stream. An image placed after the text draws over it; placed before, the text sits on top. It is why a new watermark or stamp sometimes hides the paragraph it was meant to sit behind.

Text never reflows

Unlike a word processor, a PDF has no concept of text wrapping around an image. Nothing moves when the picture changes — which is a guarantee, and also why a replacement that needs more room cannot get it.

The pre-swap checklist

1

Extract the original first

Select the image in the editor and download it. This gives you its exact pixel dimensions and aspect ratio, which are the two numbers everything else on this page depends on.

2

Match the aspect ratio

Crop or pad your replacement to the original’s proportions before uploading. Padding with transparency in a PNG is usually better than cropping content you wanted to keep.

3

Check the effective DPI

Divide your replacement’s pixel width by the frame’s width in inches. Aim for 300 for print and at least 150 for anything that will be viewed at full size on screen.

4

Pick the right format

PNG when the image needs transparency or has hard edges and flat colour, such as a logo or a diagram. JPG for photographs, where its compression is efficient and its lack of alpha does not matter.

5

Swap and check the neighbours

Replace the image, then look at the caption, the surrounding text and any border or rule. The frame has not moved, so anything that now looks wrong is a property of the new file rather than the page.

What changes and what does not

What replacing an image actually changes in the file.

 Replacing in placeRebuilding the page
Image positionUnchanged — same matrixRecalculated from the layout
Frame sizeUnchangedMay adapt to the new image
Surrounding textUntouchedRe-flowed around the new image
Aspect ratio handlingYours must match the frameThe layout adapts to yours
The old imageObject replaced, not coveredDiscarded with the rest of the page
Everything else on the pageExported unchangedRe-rendered

The trade is explicit: in-place replacement guarantees nothing moves, at the cost of requiring your image to fit a frame that already exists.

What a swap cannot do

Vector logos are not images

Many logos are drawn as vector paths rather than placed as raster images, so there is nothing to select and replace. The practical route there is to cover the region and place the new logo on top of it.

The frame will not resize itself

A replacement is stretched into the rectangle the original occupied. If the new artwork genuinely needs a different shape, the honest options are to letterbox it with transparency or to place a new image and remove the old one.

Upscaling cannot add detail

Enlarging a small image to fill a large frame produces softness that no setting fixes. Effective DPI is decided by the pixels you supply, not by the export.

Getting it right first time

Keep a transparent master of every logo

A PNG at generous dimensions, with alpha, sized to the largest frame you ever use. It makes every future swap a thirty-second job instead of a design task.

Overshoot the resolution, never undershoot

A slightly oversized image costs kilobytes and compresses well. An undersized one is visible in print and cannot be fixed after the fact.

Swap every instance, including the header

Logos repeat across headers, footers and cover pages. A document carrying two versions of the same logo is worse than one carrying the old version consistently.

Deleting is not the same as covering

If the image is confidential, remove it. Drawing a shape over it leaves the pixels in the file for anyone who extracts the images.

Frequently asked questions

  • Because a PDF draws an image into a rectangle defined by a transformation matrix, and your replacement is stretched to fill that rectangle whatever its own proportions are. If the original was 4:3 and your replacement is 16:9, the picture is squashed rather than cropped. Matching the original’s aspect ratio before you upload is the fix.

  • Work from effective DPI, not from the file’s metadata: divide your image’s pixel width by the frame’s width in inches. Target 300 DPI for anything that will be printed and at least 150 for on-screen viewing at full size. A 300-pixel-wide image in a 2-inch frame is 150 DPI no matter what the file says.

  • No. A PDF has no concept of text wrapping around an image — the positions of every text run were fixed when the file was made. Replacing the pixels inside an existing frame cannot cause anything else on the page to move.

  • PNG when the image needs a transparent background or has hard edges and flat colour, which covers most logos, diagrams and screenshots. JPG for photographs, where its compression is far more efficient and the lack of an alpha channel does not matter. Using JPG for a logo is the most common cause of an unwanted white box behind it.

  • Because it was saved as a JPG, which has no alpha channel, so the transparent area became white. Re-export the logo as a PNG with transparency and place it again. If the background behind it is white anyway you will not notice — which is exactly why this only shows up on coloured pages.

  • Stacking order. Objects are drawn in the order they appear in the page’s content stream, so an image placed before the text is drawn underneath it. Moving the image to the front, or explicitly sending it behind when you want a background, resolves it.

  • Not selectively. A scanned page is a single image, so "the picture on the page" is not a separate object — it is a region of pixels inside one large one. You can place a new image over the region, but there is no smaller image underneath to swap.

  • Not when the image object itself is replaced rather than drawn over. If a tool instead places the new picture on top of the old one, the original is still in the file and can be pulled out by anyone extracting its images — which matters when the picture being replaced was the sensitive part.