Foundation
Raspberry Pi
Documentation
Computers
Accessories
Microcontrollers
Services
Pico C SDK
ConIguration
The raspi-config Tool
Edit this on GitHub
raspi-config is the Raspberry Pi con1guration tool
originally written by Alex Bradbury. To open the
con1guration tool, type the following on the command
line:
sudo raspi-config
The sudo is required because you will be changing 1les
that you do not own as the pi user.
NOTE
If you are using the Raspberry Pi desktop then you
can use the graphical Raspberry Pi
Configuration application from the Preferences
menu to con1gure your Raspberry Pi.
You should then see a blue screen with options in a grey
box:
NOTE
The menu shown may differ slightly.
Use the up and down arrow keys to move the highlighted
selection between the options available. Pressing the
right arrow key will jump out of the Options menu and
take you to the <Select> and <Finish> buttons.
Pressing left will take you back to the options.
Alternatively, you can use the Tab key to switch between
these.
Generally speaking, raspi-config aims to provide the
functionality to make the most common con1guration
changes. This may result in automated edits to
/boot/config.txt and various standard Linux
con1guration 1les. Some options require a reboot to take
effect. If you changed any of those, raspi-config will
ask if you wish to reboot now when you select the
<Finish> button.
NOTE
In long lists of option values (like the list of timezone
cities), you can also type a letter to skip to that section
of the list. For example, entering L will skip you to
Lisbon, just two options away from London, to save
you scrolling all the way through the alphabet.
List of Options
NOTE
Due to the continual development of the raspi-
config tool, the list of options below may not be
completely up to date. Also please be aware that
different models of Raspberry Pi may have different
options available.
NOTE
All options are available via a non-interactive
command line interface. See the section on the
raspi-config command line interface for more
information.
System Options
The system options submenu allows you to make
con1guration changes to various parts of the boot, login
and networking process, along with some other system
level changes.
Wireless LAN
Allows setting of the wireless LAN SSID and passphrase.
Audio
Specify the audio output destination.
Password
You can change the 'default' user password.
NOTE
Until recently the default user on Raspberry Pi OS was
pi with the password raspberry. The default user is
now set on 1rst boot using a con1guration wizard.
Hostname
Set the visible name for this Raspberry Pi on a network.
Boot / Auto login
From this submenu you can select whether to boot to
console or desktop and whether you need to log in or not.
If you select automatic login, you will be logged in as the
pi user.
Network at Boot
Use this option to wait for a network connection before
letting boot proceed.
Splash Screen
Enable or disable the splash screen displayed at boot
time
Power LED
If the model of Raspberry Pi permits it, you can change
the behaviour of the power LED using this option.
Display Options
Resolution
De1ne the default HDMI/DVI video resolution to use when
the system boots without a TV or monitor being
connected. This can have an effect on RealVNC if the
VNC option is enabled.
Underscan
Old TV sets had a signi1cant variation in the size of the
picture they produced; some had cabinets that
overlapped the screen. TV pictures were therefore given a
black border so that none of the picture was lost; this is
called overscan. Modern TVs and monitors don’t need the
border, and the signal doesn’t allow for it. If the initial text
shown on the screen disappears off the edge, you need to
enable overscan to bring the border back.
Any changes will take effect after a reboot. You can have
greater control over the settings by editing con1g.txt.
On some displays, particularly monitors, disabling
overscan will make the picture 1ll the whole screen and
correct the resolution. For other displays, it may be
necessary to leave overscan enabled and adjust its
values.
Pixel Doubling
Enable/disable 2x2 pixel mapping.
Composite Video
On the Raspberry Pi 4, enable composite video. On
models prior to the Raspberry Pi 4, composite video is
enabled by default so this option is not displayed.
Screen Blanking
Enable or disable screen blanking.
Interfacing Options
In this submenu there are the following options to
enable/disable: Camera, SSH, VNC, SPI, I2C, Serial, 1-wire,
and Remote GPIO.
Camera
Enable/disable the CSI camera interface.
SSH
Enable/disable remote command line access to your
Raspberry Pi using SSH.
SSH allows you to remotely access the command line of
the Raspberry Pi from another computer. SSH is disabled
by default. Read more about using SSH on the SSH
documentation page. If connecting your Raspberry Pi
directly to a public network, you should not enable SSH
unless you have set up secure passwords for all users.
VNC
Enable/disable the RealVNC virtual network computing
server.
SPI
Enable/disable SPI interfaces and automatic loading of
the SPI kernel module, needed for products such as
PiFace.
I2C
Enable/disable I2C interfaces and automatic loading of
the I2C kernel module.
Serial
Enable/disable shell and kernel messages on the serial
connection.
1-wire
Enable/disable the Dallas 1-wire interface. This is usually
used for DS18B20 temperature sensors.
Remote GPIO
Enable or disable remote access to the GPIO pins.
Performance Options
Overclock
On some models it is possible to overclock your
Raspberry Pi’s CPU using this tool. The overclocking you
can achieve will vary; overclocking too high may result in
instability. Selecting this option shows the following
warning:
Be aware that overclocking may reduce the lifetime of
your Raspberry Pi. If overclocking at a certain level
causes system instability, try a more modest overclock.
Hold down the Shift key during boot to temporarily
disable overclocking.
GPU Memory
Change the amount of memory made available to the
GPU.
Overlay File System
Enable or disable a read-only 1lesystem
Fan
Set the behaviour of a GPIO connected fan
Localisation Options
The localisation submenu gives you these options to
choose from: keyboard layout, time zone, locale, and
wireless LAN country code.
Locale
Select a locale, for example en_GB.UTF-8 UTF-8.
Time Zone
Select your local time zone, starting with the region, e.g.
Europe, then selecting a city, e.g. London. Type a letter to
skip down the list to that point in the alphabet.
Keyboard
This option opens another menu which allows you to
select your keyboard layout. It will take a long time to
display while it reads all the keyboard types. Changes
usually take effect immediately, but may require a reboot.
WLAN Country
This option sets the country code for your wireless
network.
Advanced Options
Expand Filesystem
This option will expand your installation to 1ll the whole
SD card, giving you more space to use for 1les. You will
need to reboot the Raspberry Pi to make this available.
WARNING
There is no con1rmation: selecting the option begins
the partition expansion immediately.
GL Driver
Enable/disable the experimental GL desktop graphics
drivers.
GL (Full KMS)
Enable/disable the experimental OpenGL Full KMS (kernel
mode setting) desktop graphics driver.
GL (Fake KMS)
Enable/disable the experimental OpenGL Fake KMS
desktop graphics driver.
Legacy
Enable/disable the original legacy non-GL VideoCore
desktop graphics driver.
Compositor
Enable/Display the xcompmgr composition manager
Network Interface Names
Enable or disable predictable network interface names.
Network Proxy Settings
Con1gure the network’s proxy settings.
Boot Order
On the Raspberry Pi 4, you can specify whether to boot
from USB or network if the SD card isn’t inserted. See this
page for more information.
Bootloader Version
On the Raspberry Pi 4, you can tell the system to use the
very latest boot ROM software, or revert to the factory
default if the latest version causes problems.
Update
Update this tool to the latest version.
About raspi-conIg
Selecting this option shows the following text:
This tool provides a straightforward way of doing i
Although it can be run at any time, some of the opt
Finish
Use this button when you have completed your changes.
You will be asked whether you want to reboot or not.
When used for the 1rst time, it’s best to reboot. There will
be a delay in rebooting if you have chosen to resize your
SD card.
The raspi-config
Command Line Interface
The raspi-config tool can also be run in a non-
interactive mode, which is useful for setting up a
Raspberry Pi image for distribution.
sudo raspi-config nonint <command> <arguments>
The sudo is required because you will be changing 1les
that you do not own as the pi user.
NOTE
There is no consistent meaning for 0 and 1 in
arguments. Each function will document what 0 and 1
mean for that function.
List of Options
NOTE
Due to the continual development of the raspi-
config tool, the list of options below may not be
completely up to date. Also please be aware that
different models of Raspberry Pi may have different
options available.
Wireless LAN
Allows setting of the wireless LAN SSID and passphrase.
sudo raspi-config nonint do_wifi_ssid_passphrase <s
Hidden: 0 = visible, 1 = hidden. Defaults to visible. Plain: If
plain is 1, the default, passphrase is quoted
Example:
sudo raspi-config nonint do_wifi_ssid_passphrase my
sudo raspi-config nonint do_wifi_ssid_passphrase my
sudo raspi-config nonint do_wifi_ssid_passphrase my
Audio
Specify the audio output destination.
sudo raspi-config nonint do_audio <N>
Raspberry Pi 4B+
0 - bcm2835 Headphones
1 - vc4-hdmi-0
2 - vc4-hdmi-1
Password
You can change the 'default' user password.
NOTE
Until recently the default user on Raspberry Pi OS was
pi with the password raspberry. The default user is
now set on 1rst boot using a con1guration wizard.
sudo raspi-config nonint do_change_pass
NOTE
This does not check for the interactive eag and will
show full-screen messages.
Hostname
Set the visible name for this Raspberry Pi on a network.
sudo raspi-config nonint do_hostname <hostname>
Network at Boot
Use this option to wait for a network connection before
letting boot proceed.
sudo raspi-config nonint do_boot_wait <0/1>
0 - Boot without waiting for network connection 1 - Boot
after waiting for network connection
Splash Screen
Enable or disable the splash screen displayed at boot
time
sudo raspi-config nonint do_boot_splash <0/1>
0 - Enable splash screen 1 - Disable splash screen
Power LED
If the model of Raspberry Pi permits it, you can change
the behaviour of the power LED using this option.
sudo raspi-config nonint do_leds <0/1>
0 - Flash for disk activity 1 - Be on constantly
Display Options
Resolution
De1ne the default HDMI/DVI video resolution to use when
the system boots without a TV or monitor being
connected. This can have an effect on RealVNC if the
VNC option is enabled.
sudo raspi-config nonint do_resolution <group> <mod
Group: 2 = DMT, otherwise = CEA Mode: 0 = Default
Automatic
Underscan
Old TV sets had a signi1cant variation in the size of the
picture they produced; some had cabinets that
overlapped the screen. TV pictures were therefore given a
black border so that none of the picture was lost; this is
called overscan. Modern TVs and monitors don’t need the
border, and the signal doesn’t allow for it. If the initial text
shown on the screen disappears off the edge, you need to
enable overscan to bring the border back.
Any changes will take effect after a reboot. You can have
greater control over the settings by editing con1g.txt.
On some displays, particularly monitors, disabling
overscan will make the picture 1ll the whole screen and
correct the resolution. For other displays, it may be
necessary to leave overscan enabled and adjust its
values.
sudo raspi-config nonint do_overscan <0/1>
0 - Enable overscan 1 - Disable overscan
Pixel Doubling
Enable/disable 2x2 pixel mapping.
sudo raspi-config nonint do_pixdub <0/1>
0 - Enable pixel doubling 1 - Disable pixel doubling
Composite Video
On the Raspberry Pi 4, enable composite video. On
models prior to the Raspberry Pi 4, composite video is
enabled by default so this option is not displayed.
sudo raspi-config nonint do_composite <0/1>
0 - Enable composite video 1 - Disable composite video
Screen Blanking
Enable or disable screen blanking.
sudo raspi-config nonint do_blanking <0/1>
0 - Enable screen blanking 1 - Disable screen blanking
Interfacing Options
In this submenu there are the following options to
enable/disable: Camera, SSH, VNC, SPI, I2C, Serial, 1-wire,
and Remote GPIO.
Camera
Enable/disable the CSI camera interface.
sudo raspi-config nonint do_camera <0/1>
0 - Enable camera 1 - Disable camera
SSH
Enable/disable remote command line access to your
Raspberry Pi using SSH.
SSH allows you to remotely access the command line of
the Raspberry Pi from another computer. SSH is disabled
by default. Read more about using SSH on the SSH
documentation page. If connecting your Raspberry Pi
directly to a public network, you should not enable SSH
unless you have set up secure passwords for all users.
sudo raspi-config nonint do_ssh <0/1>
0 - Enable SSH 1 - Disable SSH
VNC
Enable/disable the RealVNC virtual network computing
server.
sudo raspi-config nonint do_vnc <0/1>
0 - Enable VNC 1 - Disable VNC
SPI
Enable/disable SPI interfaces and automatic loading of
the SPI kernel module, needed for products such as
PiFace.
sudo raspi-config nonint do_spi <0/1>
0 - Enable SPI 1 - Disable SPI
I2C
Enable/disable I2C interfaces and automatic loading of
the I2C kernel module.
sudo raspi-config nonint do_i2c <0/1>
0 - Enable I2C 1 - Disable I2C
Serial
Enable/disable shell and kernel messages on the serial
connection.
sudo raspi-config nonint do_serial <0/1/2>
0 - Enable console over serial port 1 - Disable serial port 2
- Enable serial port
1-wire
Enable/disable the Dallas 1-wire interface. This is usually
used for DS18B20 temperature sensors.