How to Prevent Office Macros from Reducing Image Resolution
Question details
Images inserted via VBA macros appear compressed or in low quality.

- Product
- Microsoft Office
- Device & OS
- Windows and macOS
- Scenario
- Running a VBA macro script to automate the insertion of images into a document or spreadsheet.
- Observed behavior
- The inserted images lose resolution and become blurry because Office updates or default settings aggressively compress them.
Verify your current version of Microsoft Office and ensure you have high-resolution backups of your original image files before modifying macro settings.
Disable Image Compression in Advanced Options (Windows)
Stop Windows versions of Office from automatically compressing inserted media by changing the default document quality settings.
By default, Microsoft Office applications often apply standard compression to inserted pictures to keep file sizes small. Disabling this feature ensures your macros can insert pictures at their true resolution.
Launch your Office application (such as Excel or Word) and navigate to File > Options in the top-left corner.
In the Options dialog box, click on 'Advanced' in the left-hand sidebar and scroll down to the 'Image Size and Quality' section.
Check the box next to 'Do not compress images in file' and set the default resolution dropdown menu to 'High fidelity'. Click OK to save changes.

Adjust Picture Format Settings (macOS)
Change the picture compression parameters directly from the macOS Office ribbon to maintain original image quality.
Optimize VBA Code for Image Insertion
Rewrite the picture insertion line in your VBA macro to explicitly bypass standard compression.
Avoid Unwanted Document Changes with WPS Office
If background Office updates frequently disrupt your macro settings or image resolutions, try migrating your workflow to WPS Office. It delivers reliable performance, respects your document quality settings, and handles VBA macros smoothly.
- 1. Download and Install: Visit the official WPS Office website and download the free software for your operating system.
- 2. Open Your Macro File: Launch WPS Office and open your existing macro-enabled document to instantly resume your work.
- 3. Enable Macros: Follow the on-screen prompt to enable macros safely and run your scripts with high-fidelity output.

Frequently Asked Questions
Why do my images look blurry immediately after the macro runs?
Office applications default to compressing images to save file size. Macros inserting images inherit these baseline compression behaviors unless explicitly disabled in the Advanced Options or overridden within the code.
Can I prevent image compression across all my documents automatically?
The 'Do not compress images in file' setting typically applies only to the current document. To apply it globally, you must configure this setting in a blank document and save it as your default template (.dotm or .xltm).
What should I do if the macro issue started after a recent Office update?
Updates can sometimes alter default registry keys or background behaviors. If the problem is new, consider testing an earlier Office build (rolling back the update) and submit a bug report through the application's Feedback menu.




