Editing Config Files on Your Phone: Doing It Carefully
What configuration files are, the common formats, and sensible precautions before making a quick edit.
Configuration files ("config files") control how programs behave. You may need to change one, for example a setting in a project, a server or a game. A text editor is all it takes, but care is essential.
What is a config file?
A config file is a plain-text file that stores settings. Common types:
| Extension or name | Typical use |
|---|---|
| .ini | simple settings in sections |
| .conf / .cfg | general configuration |
| .json | structured settings |
| .yaml / .yml | structured settings, using indentation |
| .env | environment variables |
| .properties | key-value settings |
| .xml | structured settings using tags |
Before you edit
- Make a copy. Duplicate the file, and name the copy something like settings.ini.bak.
- Know what you're changing. Read the documentation or comments.
- Change one thing at a time, so you can find what caused a problem.
- Check the format. Each type has its own rules.
- Keep the same encoding and line endings.
Format tips
- INI: keys and values look like name=value, with sections in [brackets].
- JSON: needs correct quotes, commas and brackets.
- YAML: uses spaces for indentation. Tabs usually aren't allowed, and misaligned lines change the meaning.
- .env: each line is NAME=value. Don't add spaces around =.
Secrets
Some config files contain passwords, keys or tokens. Treat them carefully:
- Don't share or paste them in public places.
- Avoid sending them by email or chat.
- Think about where you back them up.
After editing
- Save the file.
- Restart or reload the program if needed.
- Test that it works.
- If it fails, restore your backup copy.
Comments
Many config formats allow comments, usually starting with # or ;. Add notes such as "changed on 2027-02-10, was 8080". Future you will be grateful.
When not to edit
If you don't understand a setting, or the file controls something critical, ask someone who does before changing it.
A quick edit anywhere
For a quick, careful change, a small editor that opens plain-text files fast is all you need.
Notepad+ Text Editor
A fast, advanced text editor for notes and code, with emoji support
More about Notepad+ Text Editor
Editing README Files and Project Notes
What a README is, what belongs in one, and how to keep project notes tidy in plain text.
Read article →JSON Basics: The Punctuation That Breaks Files
A beginner's guide to reading and editing JSON files, the rules for commas, quotes and brackets, and the mistakes that cause errors.
Read article →Quick HTML Edits: Fixing a Web Page from Your Phone
How HTML is structured and how to make small, safe changes to a page in a text editor, such as fixing a typo or a link.
Read article →Tabs or Spaces? Indentation in Plain Text and Code
Why indentation matters, the difference between tabs and spaces, and how to avoid mixed-indentation problems when editing files.
Read article →