If your XML is previously exported Intellij you can simply do:

File > Import Settings > select your xml

If its custom defined, one you can try copying your xml to intellij config directory:

config/codestyles

Assuming your xml is in format intellij can understand, it will then show up in

Code Styles > Manage

If your XML is in different format, try to match tags with one of pre-defined styles(also XML)

Answer from hitz on Stack Overflow
🌐
JetBrains
jetbrains.com › help › idea › settings-code-style-xml.html
Code Style. XML | IntelliJ IDEA Documentation
August 6, 2026 - Use this page to configure formatting options for XML files. When you change these settings, the Preview pane shows how this will affect your code.
🌐
JetBrains
jetbrains.com › help › idea › configuring-code-style.html
Code style schemes | IntelliJ IDEA Documentation
1 month ago - You can export both project-level and IDE-level schemes in the IntelliJ IDEA code style XML, Eclipse XML Profile, or EditorConfig format (if the EditorConfig plugin is enabled).
🌐
GitHub
github.com › duraspace › codestyle › blob › master › ide-support › intellij.md
codestyle/ide-support/intellij.md at master · duraspace/codestyle
Select the duraspace-intellij-java-code-style.xml (under checkstyle/ide-support in the DuraSpace resources repo directory)
Author: duraspace
🌐
GitHub
github.com › google › styleguide › blob › gh-pages › intellij-java-google-style.xml
styleguide/intellij-java-google-style.xml at gh-pages · google/styleguide
<?xml version="1.0" encoding="UTF-8"?> <code_scheme name="GoogleStyle"> <option name="OTHER_INDENT_OPTIONS"> <value> <option name="INDENT_SIZE" value="2" /> <option name="CONTINUATION_INDENT_SIZE" value="4" /> <option name="TAB_SIZE" value="2" /> <option name="USE_TAB_CHARACTER" value="false" /> <option name="SMART_TABS" value="false" /> <option name="LABEL_INDENT_SIZE" value="0" /> <option name="LABEL_INDENT_ABSOLUTE" value="false" /> <option name="USE_RELATIVE_INDENTS" value="false" /> </value> </option> <option name="INSERT_INNER
Author: google
🌐
JetBrains
jetbrains.com › help › idea › working-with-xml.html
XML | IntelliJ IDEA Documentation
IntelliJ IDEA brings powerful support for XML that includes structure validation, formatting (Ctrl+Alt+L) and indentation (Ctrl+Alt+I according to the XML code style, importing unbound namespaces, viewing code structure, unwrapping and removing ...
🌐
Medium
medium.com › swlh › configuring-google-style-guide-for-java-for-intellij-c727af4ef248
Configuring Google Style Guide for Java for IntelliJ | by Reed Odeneal | The Startup | Medium
November 16, 2020 - Next to the Scheme drop-down menu select the gear icon then Import Scheme > IntelliJ IDEA code style XML then select the intellij-java-google-style.xml file you downloaded from GitHub.
🌐
Xwiki
dev.xwiki.org › xwiki › bin › view › Community › CodeStyle › JavaCodeStyle
Java Code Style - XWiki
August 3, 2026 - You can enable "Automatically add ... you want to document. ... Download codestyle-idea.xml. Go to IntelliJ's File > Settings and to Editor > Code Style and select Import Scheme > IntelliJ IDEA Code Style XML as shown on...
Find elsewhere
🌐
Lean Tactic Reference
course.ccs.neu.edu › cs5010f18 › code-style.html
Code style
For Intellij IDEA, download intellij-java-google-style.xml and save it in the config/codestyles/ subdirectory of your IntelliJ configuration folder.
🌐
Google
google.github.io › styleguide › intellij-java-google-style.xml
intellij-java-google-style.xml
xmlns:.* ^$ BY_NAME · .*:id · http://schemas.android.com/apk/res/android · style · ^$ .* ^$ BY_NAME · .*:.*Style · http://schemas.android.com/apk/res/android · BY_NAME · .*:layout_width · http://schemas.android.com/apk/res/android · .*:layout_height ·
Top answer
1 of 1
8
  • Intellij IDEA 2017.3 has got new project code style settings format. Now all code style settings are located under <PROJECT_ROOT>/.idea/codeStyles directory with the ultimate intention to support multiple project code styles linked to different scopes. New code style settings format is also cleaner and contains all code style settings properly grouped per language. Some old legacy Java, HTML settings previously stored without any language tag are moved to "JavaCodeStyleSettings", "HTMLCodeStyleSettings" etc. respectively.

  • The old .idea/codeStyleSettings.xml is imported into two new files: .idea/codeStyles/codeStyleConfig.xml containing a link to preferred project code style and .idea/codeStyles/Project.xml with code style settings for different languages. The latter is optional and created only if there are non-default settings. If .idea directory is under version control, both files can be added to VCS too. The old codeStyleSettings.xml is kept for backwards compatibility.


Original answer (now obsolete):

  • .idea/codeStyleSettings.xml stores the project specific code style that is for sharing with the project so that all the team members have the same code style applied automatically for this specific project. Check this answer for details.

  • .idea/codeStyles/codeStyleConfig.xml is used to override the default project code style. By default it contains <option name="USE_PER_PROJECT_SETTINGS" value="true" /> so that project specific configuration from .idea/codeStyleSettings.xml is used. If you switch your code style settings to use a scheme stored in the IDE instead of the project scheme, this file will store your choice.

  • IntelliJ IDEA also has support for .editorconfig which will have the priority and override IDE and project scheme by default. Check the documentation for more details.

  • codeStyle.xml in the project root is for Eclipse IDE and is not used by IntelliJ IDEA. It can be probably used by IntelliJ IDEA as well, if you have Eclipse Code Formatter plug-in installed and configured accordingly.

🌐
GitHub
github.com › gantsign › code-style-intellij
GitHub - gantsign/code-style-intellij: Code style configuration for IntelliJ IDEA. · GitHub
Code Style Configuration for code written by GantSign using IntelliJ IDEA. This project contains two code styles: GantSign.xml · The original GantSign IntelliJ Code Style; custom code style focusing on readability and minimizing version control changes. The indent is 2 spaces (rather than 4) to make functional style code more readable (functional code often has deeper levels of nesting).
Author: gantsign
🌐
JetBrains
intellij-support.jetbrains.com › hc › en-us › community › posts › 360010865000-Storing-code-style-in-project-in-Ultimate-2021-1
Storing code style in project, in Ultimate 2021.1 – IDEs Support (IntelliJ Platform) | JetBrains
I'm trying to save a code style in our project so that it can be stored in version control, and automatically used by other developers. I've saved the file to `.idea/codeStyles/Project.xml`, and cr...
🌐
Googlesource
gerrit-review.googlesource.com › Documentation › dev-intellij.html
Gerrit Code Review - IntelliJ IDEA Setup
Go to File → Settings → Editor → Code Style. Click on the wrench icon with the tooltip Show Scheme Actions. Click on Import Scheme. Select the previously downloaded file intellij-java-google-style.xml.
🌐
GitHub
raw.githubusercontent.com › google › styleguide › gh-pages › intellij-java-google-style.xml
<?xml version="1.0" encoding="UTF-8"?> <code_scheme name="GoogleStyle">
<?xml version="1.0" encoding="UTF-8"?> <code_scheme name="GoogleStyle"> <option name="OTHER_INDENT_OPTIONS"> <value> <option name="INDENT_SIZE" value="2" /> <option name="CONTINUATION_INDENT_SIZE" value="4" /> <option name="TAB_SIZE" value="2" /> <option name="USE_TAB_CHARACTER" value="false" ...
🌐
GitHub
github.com › JonathanGiles › java-code-styles
GitHub - JonathanGiles/java-code-styles: IntelliJ IDEA code style settings · GitHub
Open IntelliJ Preferences -> Code Styles -> Java, click on the small cog icon next to the 'Scheme' dropdown. Select 'Import Scheme' -> 'IntelliJ code style XML' and browse to the codestyles directory. Select the Microsoft.xml file and load it.
Forked by 4 users
🌐
JetBrains
jetbrains.com › help › idea › settings-code-style.html
Code Style | IntelliJ IDEA Documentation
1 month ago - In this area, choose the code style scheme and change it as required. Code style scheme settings are automatically applied every time IntelliJ IDEA generates, refactors, or reformats your code.