57

What's the best application to open and edit a plist file ?

3
  • wasn't me but someone voted to close... I think if you just changed your question to be more specific about what you're trying to do it wouldn't get any 'subjective' votes. Dec 24 '10 at 21:24
  • 9
    Voting to close without commenting? Way to go, team! Dec 25 '10 at 11:01
  • 1
    This is a good question. Several times, I have wanted to open a .plist file, but even with downloading an app it looked (very) difficult, so I gave up. Mar 30 '14 at 0:39
28

A PList file, like Mankoff said, is just a specially formatted XML file, so you can actually edit and create them in a program like TextEdit.

Because of the specific nature of PLists to Development, however, using a special program like Xcode or Property List Editor becomes a much more fruitful endeavor. This is because it not only automatically formats the XML code for you, but it will actually translate the key identifiers and layers into readable words, and also for some values it will provide a drop-down menu to fill in the correct responses. Especially when dealing with iPhone plists, when multiple runtime variables can be set using the Plist, easily creating new fields and knowing what to put in them makes it so much easier.

You can get bot Xcode and PList Editor from the Apple Developer website http://developer.apple.com for free by downloading the latest Xcode release.

4
  • 8
    IIRC some plist are compressed though, which makes them unopenable in a text editor without decoding them first. Apple tools do that automatically though, and back again.
    – Lloeki
    Aug 9 '11 at 7:59
  • Well perfect, more reasons to use Xcode 4! Sep 29 '11 at 5:13
  • 6
    If only… ! But no, some .plist files are binary or something like this, and TextEdit is not enough for them. Mar 30 '14 at 0:42
  • Remember that, depending on the specific use case, there may be a tool better fit for the job, intended for editing a specific type of plist file. For instance, you can use Apple Configurator for editing iOS profiles (.mobileconfig extension) or Clover Configurator for editing Clover boot profiles.
    – Manchineel
    Nov 5 '18 at 21:50
82

If the plist file is in the XML format, you can edit it in any text editor like TextEdit. If the plist file is in the binary format, you can convert it to XML first by running:

plutil -convert xml1 file.plist

If you want to go back to binary format after editing:

plutil -convert binary1 file.plist

If you have Xcode 4.3 or later, you can use it to edit property lists in a graphical editor like this:

Xcode 4.2 and earlier came with a separate application for editing property lists (/Developer/Applications/Utilities/Property List Editor.app/).

3
  • 1
    As pointed out by this solution, it is totally possible to use plutil -convert json $file (or xml), then edit the file with any editor (like vi), and finally convert it back with plutil -convert binary1 $file.
    – 7heo.tk
    Mar 31 '15 at 0:30
  • 4
    plutil -p <file> will "print property list in a human-readable fashion" instead of converting it
    – dentarg
    Mar 1 '18 at 22:05
  • 2
    This is the more complete answer and should be the accepted one. For example, you can't directly edit ~/Library/Preferences/.GlobalPreferences.plist without conversion. Sep 26 '18 at 13:20
8

A fine program like TextWrangler can edit binary .plist files without first converting them using Terminal. Simply open the file like you would any other (i.e. drag-and-drop on the program icon, or the File open dialog, or Open With in the Finder or...)

3
  • 1
    But the values are unreadable. Mar 30 '14 at 0:46
  • Thanks for sharing this tip, Daniel. I have TextWrangler's big brother, BBEdit, and I had no idea that I had a nice plist editor all along. :) Feb 8 at 21:45
  • 1
    @ScottJohnson BBEdit is both TextWrangler's big brother and successor (but it has an option now to use the old TextWrangler icon! Yay!)
    – Daniel
    Feb 9 at 18:57
4

Since Apple got rid of the GUI Property List Editor, Xcode is the best free option if you want to be sure of the result.

There are some gotcha's using a generic code editor to edit plist files. Since dictionaries use entries like

<key>some key</key>
<string>some value</string>
<key>another key with boolean value</key>
<true />

You can create a valid XML file that is not a valid plist file, for example:

<key>some key</key>
<!-- oops, forgot to enter a value - still valid XML -->

<!-- valid XML, not a plist -->
<key>another key with boolean value</key>
<true>yes</true>

If you're willing to go commercial, Plistinator will edit both binary and XML plist files.

Full-disclosure: I'm the author of Plistinator and the $12.99 it costs pays for my ramen and rent.

2
  • does it better than XCode?
    – georgexsh
    Nov 15 '17 at 8:36
  • Xcode is better than Plistinator on Mac - the UI is better, and its canonically Apple. It can be a pain as you have to install the whole of Xcode just to get the editor tool. Plistinator does do the directory search/scan and it also has a large edit field for entering free form text into values. Those features make Plistinator excellent for jobs like data driven apps and games. But for most jobs Xcode's editor is better.
    – sez
    Nov 16 '17 at 6:00
4

Free Visual Studio Code editor can open, edit and save plist files in binary format with the help of the Binary Plist extension:

A Visual Studio Code extension that enables editing of binary property list files as XML. It is inspired by the BinaryPlist Sublime Text package, although the experience is not as seamless (the user must agree to opening a binary file and the editing takes place in an additional tab). A virtual file system is used to achieve this using the FileSystemProvider API.

The extension is cross-platform but primarily uses the macOS plutil binary for conversion, the Python plistlib is used as an alterntative if available. The node package simple-plist is used as a fallback but due to JavaScript not having a float type real values that are whole numbers will be cast to integer types (a warning dialog is shown first).

4

On a Terminal window, you can use PlistBuddy, available at /usr/libexec/PlistBuddy.

PlistBuddy can read and modify values inside of a plist, either interactively or directly on the command line.

However, PlistBuddy is not a GUI editor.

Usage examples:

# Show full help
/usr/libexec/PlistBuddy -h

# Print content of plist
/usr/libexec/PlistBuddy -c print /Library/Preferences/com.apple.TimeMachine.plist

# Print selected content of plist
/usr/libexec/PlistBuddy -c 'print SkipPaths' /Library/Preferences/com.apple.TimeMachine.plist
0

I have used PlistEdit Pro for macOS and found it to be useful and comprehensively feature rich.

0

BBEdit will open plist files for editing, and do any necessary conversion of file types.

It will also handle file permission access, if needed.

You can also do things like create Text Filters to do things like encode/decode base64 encoding.

It's the essential text editor for Mac. (No connection to the company, just a user for 30 years...!)

This site is temporarily in read only mode and not accepting new answers.

Not the answer you're looking for? Browse other questions tagged .