← Back to all posts

How to Choose a Scale Factor and Algorithm When Enlarging an Image? Lanczos versus AI Upscaling

Local browser upscaling is neither lossless nor AI guessing at detail. Understand 2x/4x, Lanczos resampling and sharpening to choose between privacy and quality.

When a small image has to go onto a poster or into an ID photo layout, the first reflex is to enlarge it. But enlarging does not create detail out of nothing — the pixels are interpolated again, so edges may look crisper or may turn to mush. TwoThink's Upscale Image resamples on a Canvas locally in your browser, so the file is never uploaded, which makes it right for private images. This post covers how to choose a scale factor and an algorithm, and where the boundary with AI upscaling lies.

It is not "lossless upscaling"

"Lossless upscaling" shows up in marketing all the time, but from a signal-processing point of view it does not hold: an interpolation algorithm cannot invent texture that is not in the source, it can only smooth or sharpen the edges that are. The FAQ and the copy of this tool both stress high-quality resampling, not losslessness.

If the source resolution really is not enough, look for a higher-resolution original, or consider an AI upscaling service that requires an upload — that is a different product route.

Scale factor: 2x / 3x / 4x

  • 2x: a reasonable trade-off in size and time, and enough for most social media crops
  • 3x / 4x: for small icons and QR codes; keep an eye on the output edge length and the memory limit (16384px per side)

A very large original at 4x may be rejected, so Resize Image it down first, or pick a smaller factor.

Choosing an algorithm

AlgorithmCharacter
LanczosThe default; relatively sharp edges, good for general photos
BicubicSmoother transitions, good for gradient backgrounds
NearestPixel art and retro game assets, where you do not want smoothing

After upscaling you can switch on Unsharp Mask sharpening to make the edges crisper, but push it too far and halos appear.

Working with background removal and ID photos

An example flow: a small avatar has to go into an ID Photo layout → first 2x with Lanczos → then cut it out and change the background. The whole chain can be done locally on this site, and the EXIF orientation is corrected automatically.

Wrapping up

Lanczos upscaling in the browser equals privacy, no model download and a predictable runtime — it is not AI magic. Keep the source as sharp as you can, be restrained with the factor and sharpen only when needed; that beats firing off a blind 4x.

Try it → open Upscale Image and use the comparison slider to see the difference between the original and the 2x version.