Skip to main content
silsa
Participant
October 27, 2023
Question

Default unit millimeters when opening SVG files not pixels?

  • October 27, 2023
  • 2 replies
  • 772 views

Hello,

default unit is now millimeters when I open a SVG files. I am pretty sure it used to be pixels which makes more sense to me. Or was this information earlier saved within the file but not anymore/Illustrator not reading it?

 

macOS Sonoma 14.0

Illustrator 28.0

2 replies

Participant
April 2, 2025

Just picking this back up in 2025 for anyone else frustrated with this. It was undoubidly the case that when saving an AI file as an SVG the width and height of that SVG would be set in pixels regardess of the units of measurement used in the document, at some point in the last couple of years that changed, the units used in the document were matched in the SVG.

 

This is troublesome as a lot of third party apps only recognise pixels. For example I use SVG files for a CNC router and the firmware crashes if you use anything but pixels. Until today I have typically saved the SVG, opened it in TextEdit and then manually changed the width and height of the SVG to match the pixel values used in viewBox. 

As mentioned above, a helpful and quick solution to this is to right-click on the document rulers change the units to pixels and then export the SVG. Once saved, revert the rulers back to the working units. 

However, this feels hacky, I can't help but feel there should be an option within the SVG Options dialogue to "match the document units"  if left unchecked the SVG will use pixels. 

macOS Sequoia 15.4
Illustrator 29.4

Community Manager
April 2, 2025

Hello @hesken,

I understand that this functionality is important to you. Would you mind creating a UserVoice for this feature request (https://adobe.ly/3YeAf2N) and adding your comments there? Doing this will help us prioritize this request, and you will be notified of any updates.

 

Feel free to reach out if you have more questions or need assistance. We'd be happy to help.

 

Anubhav

Ton Frederiks
Community Expert
Community Expert
October 27, 2023

There is no unit saved when you export an SVG. 

The last opened/created file or the last set unit in the Preferences is used when opening an SVG.

silsa
silsaAuthor
Participant
October 27, 2023

My general unit is millimeters. But it doesn't matter what the last set unit is. If I open a SVG file and change the unit to pixels, close the file and open it again, it's again in millimeters. I'm pretty the behavior is now different in AI. I've worked with lots of SVG files in past all the time but after the latest update I started noticing this unit thingy.

Ton Frederiks
Community Expert
Community Expert
October 27, 2023

"If I open a SVG file and change the unit to pixels, close the file and open it again, it's again in millimeters."

Do you save the SVG or do you change the unit in Preferences?