Articles on: Minecraft

How to Properly Edit a Server Config File Depending on its Type




To customize your Minecraft server experience, you can edit and change lots of options. To do so, you usually need to edit one of the server's config files, then restart the server.

A Minecraft server can use multiple types of config files, and each of them usually has its specific way of editing. If you change a config file improperly, your server may crash, or the option you try to change may not work properly.

This guide will assist you in correctly accessing and editing your server configuration files based on their type (extension).


📁 Change the Config Files via the Multicraft Panel 📁



To change your server configuration files you have to do the following steps:

Log in to your Multicraft panel here and stop your server.


Click on Files, then on Config Files.

Config Files


Click on the config file you want to edit.



NOTE: Here you will find a list with all configuration files detected by the server, including the default server.settings file which can be found under the name Server Settings.


Change what you need, then click on Save and start your server.



You have successfully edited your desired server configuration file.


🗄️ Change the Config Files Manually 🗄️



You can anytime change the configuration files of your server manually by accessing the server files.

To do so, please follow the next steps:

Log in to your Multicraft panel here and stop your server.


Click on Files, then on FTP Files Access.

FTP Files Access


Find the config file you want to edit in the server root directory, then click on it and click on Edit.




Change what you want, then click on Save and start your server.



You have successfully manually edited your desired server configuration file.


📝 Types of Config Files 📝



You will usually find the following types of config files on your server:

- .JSON
- .CONF
- .TOML
- .YAML

You can edit config files either using the Multicraft Web FTP by opening the file or by downloading it and opening it with a text editor like Notepad++.

Here is our guide for using the Multicraft Web FTP.


🔰 JSON Type 🔰



In Minecraft, the JSON file format is used to store things like the OP player or banned players. It is also used by some mods.

Examples of JSON files on a Minecraft server:

- ops.json
- whitelist.json
- banned-players.json

NOTE ⚠: It is recommended to use commands to edit JSON files, and not edit them manually, as they have a specific format type and will crash the server if improperly edited. You can OP players, ban them, or add them to your whitelist using in-game commands.
Here you can find more information about JSON files.


But you can also edit the JSON files manually. When you edit a JSON file, you need to strictly follow the format. But if you have any doubts, we provide the JSON Format tool, which will tell you if the file is edited correctly or not.

We have a guide here for using the JSON Format tool.
NOTE ⚠: JSON files do not allow comments, so you will find no information regarding options inside the file. Usually, mods with a JSON config will have to also provide documentation explaining what is each option doing.


💠JSON General Formatting Rules:



JSON files, as previously stated, have a specific editing type. Here are the main rules:

JSON files are typically organized as keys followed by the value of the key. Those keys need to be put between double quotes ("), followed by a colon (:), and then the value of the keys between double quotes too ("). Example: "key": "value".

The value field can also be a number. If this is the case, the number will not be put between double quotes ("). Example: "key": 10.

The value files can also be an array of values associated with that key. If this is the case, the array needs to be put between square brackets ([]).

The value filed can also be an object, which is a sublist of keys and values. If this is the case, they need to be put between curly brackets ({}).

The value filed can also be a boolean value, meaning true or false. If this is the case, they will be placed without any additional brackets or quotes. Example: "key": true.

The value filed can also be null, meaning nothing.

Key-value pairs must be enclosed in curly brackets ({}) and separated with a comma (,).


Example of an entire JSON file containing values as strings, numbers, arrays, and objects:

{

    "key1": "option1",
    "key2": "option2",
    "key3": [
        "option3_1",
        "option3_2",
        10
    ]
    "key4": {
        "key4_1": "option4_1",
        "key4_2": 10
    }
}



🔰 CFG or CONF Type 🔰



The CFG config file type is usually used by mods for their configuration.

The majority of mods using a CFG file will have all the tags that they need already in the file, along with a brief description in a comment regarding what they do.

The comments will help you understand what each option does.


💠CFG General Formatting Rules:



CFG files have a specific editing type, too. Here are the main rules:

You usually use the tag name, followed by the =, then the value. Example: tag = value.

All comments begin with #. They are just extra information, so you understand what each tag is doing.

You can also set multiple values for a single tag using > before the tag, and < at the end.


Example of an entire CFG file:

tag1 = value1
# This is a comment that will help you understand the purpose of tag1


> tag2
value1
value2
<
# Here you can find the tag2 with multiple values



🔰 TOML Type 🔰



The TOML file is typically used by mods for configuration and by Forge modded servers to determine which mods are packaged into your JAR file and what information to display in the mods listing screen, which is typically accessed by clicking on the Mods button on your client's main menu.

Here you can find more information about TOML files.
If you have any doubts when manually editing TOML files, you can use a TOML validator, which will tell you if the file is edited correctly or not, pointing out any mistakes.


💠TOML General Formatting Rules:



TOML files have a specific editing type too. Here are the main rules:

TOML files are usually structured as keys and then the value of the key. These keys are followed by an =, and the value is enclosed in double quotes ("). Example: key1 = "value1".

The value field can also be a number. If this is the case, the number will not be put between double quotes ("). Example: key1 = 10.

The value files can also be an array, which is a list of values associated with that key, If this is the case, the array needs to be put between square brackets ([]) and the values separated by a comma (,). Example: ports = [ 8000, 8001, 8002 ]

Tables, which are collections of key-value pairs, can also be used. The table name should be enclosed in square brackets ('[]'), followed by the keys and values on separate lines.

All comments begin with #. They are just extra information, so you understand what each tag is doing.


Example of an entire TOML file:

key1 = "value1"
# Comment explaining the key1.

key2 = [ 1, 2 ]

[table_name]
key2 = 1
key3 = "value2"
# Comment explaining the table content.



🔰 YAML or YML Type 🔰



The YAML files are usually used by Minecraft plugins to store their configuration settings.

Improperly editing a YAML file can cause the plugin using it to not load properly or not work on your server.

Here you can find more information about YAML files.
If you have any doubts when manually editing YAML files, you can use a YAML validator, which will tell you if the file is edited correctly or not, pointing out any mistakes.


💠YAML General Formatting Rules:



YAML files have a specific editing type, too. Here are the main rules:

Indentations are commonly used in YAML files to denote different structure levels. You can use any number of spaces for indentations, but usually, two spaces will do the task. The TAB character should not be used for indentations.

All comments begin with #. They are just extra information, so you understand what each tag is doing.

Items in lists are used with the hyphen (-) at the start and are usually separated on new lines.

Items in lists can also be used between square brackets ([]) with a comma and a space (,) separating them.

Keys and values separated by a colon and a space (:) are used to represent dictionary items. Keep in mind that items on the same indentation level cannot have the same key. Example: key1: value1.

Dictionary entries may also be used between curly braces ({}) and separated by a comma and a space (,).

You can use quotes (') or double quotes (") for keys or values if you need to include whitespace.

Double quotes (") can also be used for strings containing special characters.


Example of an entire YAML file:

# Comment explaining options
string: Here you can input your string
number: 15 # You can also put a comment here explaining an option
array1: [string1,"string2: Using a special character!"]
array2:
  - string1
  - string2
associative array1:
  key1: value1
  key2: value2
  key3: [can, also, be, an, array]
  key4:
    key4-1: "You can also nest!"
associative array2: {key1: value1, key2: value2}



If you find any issues, contact us on live chat or via the ticket system.


❕Useful Links❕



- How To: Edit Mod configuration files
- How to Edit Your Server Configuration Files
- How to Use the JSON Validator (JSON Error Type)

Updated on: 08/01/2023

Was this article helpful?

Share your feedback

Cancel

Thank you!