Skip to main content
margf90845199
Inspiring
January 4, 2019
Answered

Export with specific pixels and dpi/ppi in Illustrator

  • January 4, 2019
  • 4 replies
  • 13272 views

I have an image that is 5472 x 3648 pixels, and 300 dpi. I am trying to crop it to 250 x 250 pixels, with 150 dpi in JPG format.

When I created the document in Illustrator (File > New), I made the artboard 250 x 250, and set the Raster Effects to "Medium (150 ppi)."

When I "Save for Web (Legacy)," the image saves with the correct pixels (250 x 250), but the dpi is 96.

When I "Export as... JPEG (*JPG)," I set Quality: Medium, Compression Method: Baseline Optimized, Resolution: Medium (150 ppi), and Anti-aliasing: Art Optimized. Then, the exported file is the right dpi (150), but the pixels are 522 x 522.

How can I export so that I get the correct pixels AND correct dpi?

This topic has been closed for replies.
Correct answer margf90845199

Problem solved! For anyone else having the same issue -- use Photoshop instead of Illustrator. First select the Crop tool. Then in the top left corner, click the drop-down menu that says "Ratio" and select "W x H x Resolution." Then enter the desired pixel dimensions and ppi. So for my example, I entered "250 px x 250 px x 150 px/in."

Thanks everyone for the help!

4 replies

margf90845199
margf90845199AuthorCorrect answer
Inspiring
January 7, 2019

Problem solved! For anyone else having the same issue -- use Photoshop instead of Illustrator. First select the Crop tool. Then in the top left corner, click the drop-down menu that says "Ratio" and select "W x H x Resolution." Then enter the desired pixel dimensions and ppi. So for my example, I entered "250 px x 250 px x 150 px/in."

Thanks everyone for the help!

Legend
January 4, 2019

One key thing to know: Illustrator does not set a size in pixels. Only inches/mm. I know it seems to but it just does a simple thing of assuming you have a 72 ppi resolution and setting the size in inches/mm. You cannot change this, but if you know it does it you can work with it.

So, if you wanted to make a 250 x 250 pixel result at 150 ppi you have to work out what that actually means in inches. Easy enough, 250/150 is 1.667, near enough. So you make your original 1.667 x 1.667 inches. When you export at 150 ppi it will be 250 pixels square. Done! Except... I agree 100%, don't use Illustrator to crop images !!

Another piece of info: Save for web saves WITH NO RESOLUTION. When you believe it to be 96 ppi, it's just the default for that app. A different app will show a different resolution. This is because ppi is of absolutely no importance (repeat, none) for web graphics.

John Mensinger
Community Expert
Community Expert
January 4, 2019

Your input = raster image

Your desired output = raster image

Illustrator is a vector graphics application and the wrong tool for this task.

Do you have access to Photoshop?

Monika Gause
Community Expert
Community Expert
January 4, 2019

margf90845199  schrieb

How can I export so that I get the correct pixels AND correct dpi?

You can't.