Sometimes, you need a high-quality icon of from Mac System Preferences for project, but you can't find a good one online. Luckily, with a little digging, it's easy to extract a perfect quality System Preference icon with a transparent background using only the Preview app. Here's how.

First, we'll need to locate the actual files that represent the panes in System Preferences using Finder. With Finder active, select Go > Go to Folder from the menu bar at the top of the screen.

Click "Go To Folder" in Mac Finder.

In the "Go To Folder" window or slider that appears, type (or paste)

        /System/Library/PreferencePanes
    

.

In the Go To Folder dialog, enter the path and click "Go."

A Finder window will appear that includes files that correspond with the default preference panes you see in System Preferences.

(Note: If you are looking for a third-party preference pane file, check

        /Library/PreferencePanes
    

instead.)

Mac Preference Pane files as seen in Finder.

Locate the file representing the preference pane from which you'd like to extract an icon. It should have a recognizable name. For example, "PrintAndScan.prefPane" is the file for "Printers & Scanners," and "SoftwareUpdate.prefPane" is the file for "Software Update."

Each ".prefPane" file is actually a special type of folder called a "package." We're going to open up that package and see the resources inside.

Once you find the preference pane file, right-click it and select "Show Package Contents."

Right-click the preference pane file and select "Show Package Contents."

The app package will open, and you’ll see a “Contents” folder. Open it, and within “Contents,” you’ll encounter several folders and files. Locate the “Resources” folder and open it.

In Finder on Mac, click the "Resources" folder.

Browse within the Resources folder and look for an ".icns" file with a similar name to the preference pane you're examining. For example, "SoftwareUpdate.prefPane" includes a file called "SoftwareUpdate.icns." This is an icon package file that contains different-sized icons for the prefernce pane. Double-click it, and it will open in Preview.

In Finder on Mac, locate and click on the appropriate ICNS file.

In Preview, you'll see that the ".icns" file includes icons in multiple sizes. The largest one will be at the top of the list in the pane on the left. Click to select it.

Click the largest icon in Preview on Mac.

Once you've selected the largest icon, click File > Export in the menu bar.

In Preview on Mac, select "Export" from the "File" menu.

When the Export dialog appears, enter a file name and choose a save location. Next, you'll need to decide an image format. If you want the highest quality image with a transparent background, select “PNG” from the list. (Make sure the “Alpha” option is checked, because this ensures that the PNG will have a transparent background.)

Then click “Save.”

While exporting from preview, enter the file name and click "Save."

Preview will save the icon you chose as a transparent PNG file. After that, close Preview, and you'll find the new PNG file waiting where you saved it. Very handy!