Using raspi-config to Configure Raspberry Pi OS
Learn how to launch and navigate raspi-config, then configure keyboard layouts, timezones, passwords, SSH, storage, and other Raspberry Pi OS settings.
raspi-config is a menu-driven, text-based administrative utility for configuring a Raspberry Pi installation. It is included with Raspbian and Raspberry Pi OS environments that provide the utility. Instead of finding each setting in a different command or configuration file, you can use raspi-config to manage many common initial and ongoing system settings from one interface.
Because raspi-config changes operating-system settings, some actions require administrator privileges. Other changes take effect only after services restart or the Raspberry Pi reboots.
When to use raspi-config
raspi-config is commonly used during the first boot of a newly installed Raspbian or Raspberry Pi OS system. Typical first-boot tasks include selecting a keyboard layout, setting the timezone, changing the default account password, enabling SSH, and expanding the filesystem so the operating system can use the available SD card capacity.
You can reopen the utility later whenever you need to change a supported setting. The available menu entries depend on the installed operating-system version, hardware, and packages. The names and organization of options may therefore differ slightly between systems.
For broader first-boot guidance, see setting up a Raspberry Pi and installing Raspbian.
Prerequisites
- A Raspberry Pi that has completed startup and is accepting input.
- A logged-in user account.
- Access to a terminal, the text-command interface used to start administrative tools.
- Basic command-line and keyboard navigation skills.
- Knowledge of sudo, a command prefix that runs a command with administrator privileges.
If you need help opening a terminal, read using the terminal in Raspbian.
Launch raspi-config manually
- Open a terminal session from the desktop, or log in to the Raspberry Pi through an existing text console.
- Enter the following command:
sudo raspi-configPress Enter. If prompted, type the password for your account. The password is not displayed while you type it.
The command uses sudo because raspi-config modifies system-wide settings, protected files, services, or storage structures. An account must have administrator permission to run it successfully.
After the utility opens, you will see a text-based menu. Do not close the terminal while raspi-config is running.
Navigate the text interface
Use the keyboard to move through the menus:
- Up and Down arrows: move the highlight between menu entries.
- Enter: open the highlighted menu or confirm a selected choice.
- Tab or other on-screen navigation controls: move between buttons and controls when the current screen provides them.
- Finish: leave raspi-config after reviewing or applying changes.
To leave a submenu, use the displayed Back, Cancel, or equivalent control. Cancel abandons the current operation when the screen supports cancellation; it does not necessarily undo changes already confirmed in an earlier menu.
Read every confirmation message. Some operations affect partitions, services, login access, or boot behavior. If raspi-config displays a reboot prompt, choose the appropriate response and restart when the changes require it.
Core configuration areas
Keyboard layout and localization
A keyboard layout maps the physical keys on your keyboard to the characters the operating system expects. If the layout is wrong, punctuation, symbols, and special characters may appear incorrectly even though the keyboard hardware works.
- Open raspi-config and locate the localization or keyboard configuration entry.
- Choose the keyboard model if requested.
- Select the layout and variant that match the attached keyboard.
- Confirm the selection and return to the main menu.
- After leaving the utility, test several punctuation and symbol keys in a terminal or text editor.
Locale-related settings may also control language, character encoding, and regional formats. The exact options depend on the installed version.
Timezone
A timezone is the regional time setting used for the system clock, scheduled tasks, and timestamps. Select the geographic region and then the appropriate city or timezone identifier.
- Open the timezone setting.
- Choose the correct geographic region.
- Choose the appropriate city or timezone.
- Finish the configuration and verify the displayed system time.
If the time remains wrong, check the network connection and whether network time synchronization is available.
Change the pi user password
Some traditional Raspbian installations use a default account named pi. Use the password option to replace a known or weak password with a strong one. Newer installations may not contain a pi account, so use the account-management method provided by that system instead.
Choose a password that is difficult to guess and do not reuse it on other systems. Record it securely before enabling remote access. For related guidance, see changing a Raspberry Pi password.
Enable or disable SSH
SSH, or Secure Shell, is a protocol for remote command-line access to a Raspberry Pi. raspi-config can enable or disable the SSH service through an interface or remote-access option, depending on the installed version.
- Open the SSH or interfacing option.
- Enable SSH only when remote administration is needed.
- Set or confirm a secure password for the account used to connect.
- Finish the configuration and reboot if raspi-config requests it.
- From another device, test a connection using the Raspberry Pi's correct network address and valid credentials.
Disable SSH when it is not needed, and avoid exposing the service to untrusted networks. See enabling SSH in Raspbian and accessing Raspbian remotely.
Expand the filesystem
A filesystem is the disk structure through which the operating system stores and accesses files. An image written to an SD card may initially use only part of the card. The filesystem expansion option grows the installation to use available unallocated storage.
- Locate the filesystem expansion option.
- Read and confirm the operation.
- Choose Finish after the operation completes.
- Restart if prompted.
- After rebooting, check the available disk space.
For more detail, see expanding the Raspbian filesystem.
Other settings
Depending on the installed version, raspi-config may provide system, interface, boot, performance, update, and advanced settings. Examples can include boot behavior, hardware interfaces, hostname, memory allocation, camera support, and other Raspberry Pi-specific features. Read the description and confirmation prompt for each option before enabling it.
Menu availability is not identical across all Raspberry Pi models or operating-system releases. Do not assume that an option shown in another guide exists on your system.
Common raspi-config tasks
Apply changes safely
Some settings take effect immediately. Others affect services, partitions, or boot configuration and require a restart. A change may also be saved successfully but remain invisible until an application, service, or the whole Raspberry Pi is restarted.
- Complete the current option and read its result.
- Return to the main menu and review any security-sensitive changes.
- Select Finish to leave raspi-config cleanly.
- Accept a reboot prompt when the utility says one is needed.
- After restarting, test the setting: check the keyboard, verify the time, try the new password, test SSH, or inspect available disk space.
Practical configuration examples
Open raspi-config after first boot
- Open a terminal.
- Run
sudo raspi-config. - Use the arrow keys to locate the required option.
- Press Enter to open or select it.
- Complete the prompts, then choose Finish.
- Restart if prompted and verify the result.
Correct an incorrect keyboard layout
Run raspi-config, open the localization or keyboard setting, and select the layout that matches the physical keyboard. Choose Finish, then test punctuation and symbol keys in a terminal or text editor. If characters are still wrong, repeat the selection and check whether the physical keyboard has a different regional variant.
Set the local time
Open the timezone setting, select the correct geographic region, and then select the appropriate city or timezone. Exit with Finish and verify the system time. If the time is still inaccurate, check network connectivity and time synchronization.
Enable remote administration
Open the SSH or interfacing option and enable SSH only if remote terminal access is needed. Confirm a secure user password, finish the utility, and reboot if requested. From another device, test the connection using the Raspberry Pi's network address and valid account credentials.
Use the full SD card capacity
Open the filesystem expansion option and confirm it. Leave raspi-config with Finish, reboot if prompted, and check disk usage afterward. If the available space has not increased, the expansion may not have completed or the reboot may still be required.
Troubleshooting
The command cannot be run or access is denied
Check that the command is exactly sudo raspi-config. Running it without sudo may prevent system changes. Also confirm that the current account has administrator permission. If the command is missing, verify that the operating system is the expected Raspbian or Raspberry Pi OS environment and that the raspi-config package is available for that installation.
The keyboard produces unexpected characters
The selected keyboard layout probably does not match the physical keyboard. Return to the keyboard configuration option, select the correct layout and variant, then test the affected keys again.
The clock displays the wrong local time
Return to the timezone setting and choose the correct region and city. Then verify network connectivity and allow time synchronization to obtain accurate time when applicable.
SSH connections fail after configuration
Confirm that SSH was enabled, reboot if raspi-config requested it, and verify that the Raspberry Pi is connected to the network. Check that you are using the correct network address, account name, and password. A firewall or network isolation can also prevent a connection.
Available storage is smaller than the SD card size
The filesystem may not have been expanded, or the expansion may require a reboot. Run the filesystem expansion option, choose Finish, reboot if prompted, and check disk usage afterward. The usable capacity will be somewhat smaller than the card's advertised capacity because of formatting and system data.
Exam-relevant notes
- raspi-config is a menu-driven command-line utility for configuring a Raspbian installation.
sudo raspi-configlaunches it with administrator privileges.- Arrow keys move through entries, Enter selects or confirms, and Finish exits the utility.
- Common tasks include keyboard layout, timezone, pi user password, SSH, and filesystem expansion.
- Some changes are immediate; others require a service restart or system reboot.
- Always read confirmation and reboot prompts before leaving.