PyCharm 2021.3 Help

Share PyCharm Settings

Why sharing?

It is quite possible that you use one PyCharm license on different machines and on the different operating systems, for example, on your desktop at work and on your laptop at home. Another option is to share settings across a team, so that all the teammates use the same code style, live templates, or file templates. That's why it is vital to be able to share PyCharm settings, which is done by means of export and import.

PyCharm provides Export Settings command that produces the settings.zip archive. This archive contains the global settings differing from the defaults, and is stored locally. If you want to share your global settings, you have to make this archive accessible. You can do this in the numerous ways:

  • Put this archive under version control

  • Place it in your Dropbox

  • Just write it to a flash drive and stick into your pocket.

  • etc.

As soon as the archive of the global settings becomes accessible, it can be imported into another installation of PyCharm using the Import Settings command.

What this tutorial is about

This tutorial aims to walk you through exporting PyCharm global settings, sharing them via VCS, and importing them to a different PyCharm installation.

Out of scope of this tutorial are:

  • Python programming

  • Information about the project and IDE settings.

  • Information about using specific version control tools, Dropbox etc.

Before you start

Make sure that you are working with PyCharm. This tutorial is created with PyCharm version 2017.1.

Preparing an example

  • First, we'll change some settings (for example, code style, keymap, and editor color scheme). This step is required, because we are going to export the archive of global settings, that contains only the differences against the default PyCharm settings.

  • Next, we'll see where the copies of the schemes reside. This step is optional, and is intended just for your information.

  • Finally, we'll put the project under version control. This step can also be considered optional, since, as mentioned above, you can make your archive of global settings accessible in numerous ways.

Creating copies of the various schemes

We are going to create copies of the various schemes (remember, the pre-defined schemes are not editable) to further change and share them. Click Icons general settings on the main toolbar to open the Settings/Preferences dialog.

Creating a copy of the code style scheme

Follow these steps:

  1. On the Code Style page of the editor settings, click Manage.

  2. Then, in the Code Style Schemes dialog, select a scheme you want to copy, click the button Save As, and type the new scheme name:

    Copy code style scheme

Creating a copy of a keymap

In the Keymap page of the Settings/Preferences dialog, choose a scheme and click Copy:

Copy keymap

Creating a copy of the editor color scheme

Expand the Editor node of the Settings/Preferences dialog, in the Colors and Fonts page, choose the desired scheme, and click the button Save As. Then type the name of the new editor color scheme:

Copy editor color scheme

Where the copies of the setting are stored?

Storage location of the settings depends on your platform. For example, for Windows, the settings are stored in your user home, so it makes sense to look for the copies of the schemes there. Here they are, under the .PyCharm20XX.X\config directory:

Copy schemes location 1

The copies of the new schemes are added to the global settings, and as such, become sharable:

Copy schemes location

Putting the project under version control

In this example, we use PyCharm's Git integration. It is supposed that you have Git integration enabled.

To put the project under version control, click Icons general settings on the main toolbar to open the Settings/Preferences dialog, then on the Version Control page click New to add a new content root, and choose Git as the version control system:

Add vcs mapping

Refer to the section Associate a directory with a version control system .

Exporting settings

Let's export the settings. To do that, on the main menu, click File | Manage IDE Settings | Export Settings..., and then, in the Export Settings dialog, click the ellipsis to choose the target location. Since we want to use the PyCharm's Git integration, it makes sense to place the exported archive under the project root, to make the archive visible in the Project tool window, and make use of the Version Control window. Next, unselect the checkboxes to the left of the unnecessary settings, and then click OK:

Export settings

The settings.zip archive is created in the specified location. Since we have chosen the project root, we see this archive (marked as unversioned file) in the Project tool window, and in the Version Control tool window.

Actually, export is done... the only thing left is to push the archive to the repository. So first, press Ctrl+Alt+A to add the new file to version control, and commit changes:

Export settings 1

Importing settings

What's next? Let us suppose that your teammates have access to your repository and can download your settings archive. Then one has to choose File | Manage IDE Settings | Import Settings... in his/her PyCharm installation, and locate the downloaded archive (or its parent directory):

Import settings location

Next, one has to specify which settings should be imported - one can actually unselect, for example, keymap settings, if he/she is quite happy with his/her keymap:

Import settings select components

After clicking OK, PyCharm suggests to restart, for the new schemes to take effect.

More information

You may find it useful to read PyCharm documentation. Refer to the page Share your IDE settings .

Last modified: 12 April 2022