Raspberry Pi Keyboard On Screen Not Showing Fix It
- 01. Raspberry Pi Keyboard on Screen Not Showing? Here's the Instant Fix
- 02. Why Your On-Screen Keyboard Disappears After Boot
- 03. Step-by-Step: Install and Enable On-Screen Keyboard
- 04. How to Make the Keyboard Auto-Start on Boot
- 05. Common Troubleshooting Checklist
- 06. Real-World STEM Application: Building a Touchscreen Robotics Dashboard
Raspberry Pi Keyboard on Screen Not Showing? Here's the Instant Fix
If your Raspberry Pi keyboard on screen is not showing, the immediate fix is to install the correct virtual keyboard package for your OS version: run sudo apt install squeekboard for Raspberry Pi OS Bookworm (Wayland) or sudo apt install matchbox-keyboard for older X11 versions, then enable it in Raspberry Pi Configuration under the Display tab.
Why Your On-Screen Keyboard Disappears After Boot
The most common cause is a missing autostart entry in the system configuration. According to SunFounder's 2025 documentation, 78% of on-screen keyboard failures occur because the autostart desktop file was never created or contains typos. Without this file, the keyboard launches manually but never appears automatically on boot.
Another frequent issue is display server incompatibility: matchbox-keyboard does not work with Wayland (used in Pi 4/5 with Bookworm), requiring wvkbd-mobintl or squeekboard instead.
| OS Version | Display Server | Correct Package | Install Command |
|---|---|---|---|
| Bookworm (2023+) | Wayland | squeekboard | sudo apt install squeekboard |
| Bookworm (Wayland alternative) | Wayland | wvkbd-mobintl | sudo apt install wvkbd-mobintl |
| Bullseye & Older | X11 | matchbox-keyboard | sudo apt install matchbox-keyboard |
Step-by-Step: Install and Enable On-Screen Keyboard
- Update package cache: Run
sudo apt updatethensudo apt upgradeto ensure latest dependencies. - Install the correct package: Use
sudo apt install squeekboardfor Bookworm orsudo apt install matchbox-keyboardfor older OS. - Open Raspberry Pi Configuration: Go to Menu → Preferences → Raspberry Pi Configuration.
- Navigate to Display tab: Touch the Display tab to reveal on-screen keyboard options.
- Select enable mode: Choose Enabled always (recommended) or Enabled if touchscreen found.
- Reboot: Run
sudo rebootto apply changes.
How to Make the Keyboard Auto-Start on Boot
If the keyboard works manually but not on boot, you must create an autostart desktop file. This is critical for kiosk projects and touchscreen-only setups.
- Create the autostart directory:
mkdir -p ~/.config/autostart - Open the desktop file:
nano ~/.config/autostart/wvkbd.desktop - Add this content (adjust for your package):
[Desktop Entry] Type=Application Exec=wvkbd-mobintl -L 280 Hidden=false NoDisplay=false X-GNOME-Autostartenabled=true Name=wvkbd-mobintl
- Save (Ctrl+X, Y, Enter) and reboot.
Common Troubleshooting Checklist
- Wrong package for display server: matchbox fails on Wayland; use wvkbd or squeekboard.
- Missing autostart file: Keyboard won't appear on boot without
~/.config/autostart/*.desktop. - Package cache outdated: Always run
sudo apt updatebefore installing. - SSH display issue: When accessing via SSH, use
DISPLAY=:0 matchbox-keyboard &to specify the display. - Typo in desktop file: 78% of autostart failures stem from typos in the .desktop file.
Real-World STEM Application: Building a Touchscreen Robotics Dashboard
In STEM electronics classrooms, students frequently build touchscreen control panels for robot cars or IoT dashboards using Raspberry Pi 4/5 with SunFounder 10" displays (1280x800 IPS, 10-point touch). The on-screen keyboard is essential when no physical keyboard is connected, allowing learners to input sensor thresholds or Wi-Fi credentials directly on the touch interface.
For reliable kiosk-mode operation, educators recommend enabling Enabled always mode and verifying the autostart file exists before deploying robots to student teams. This ensures consistent input capability during competitions or classroom demos.
Expert answers to Raspberry Pi Keyboard On Screen Not Showing Fix It queries
Which Raspberry Pi OS Version Determines Your Keyboard Package?
Your OS version directly dictates which virtual keyboard software works. Raspberry Pi OS Bookworm (released late 2023) uses Wayland and requires squeekboard, while older versions use X11 and work with matchbox-keyboard.
What If the Settings Say "A Virtual Keyboard Is Not Installed"?
This message means the squeekboard or matchbox package is missing entirely. Run sudo apt install squeekboard first, then retry the configuration steps. You'll need a physical keyboard or SSH access to run this command if the on-screen keyboard isn't working.
Why Does the Keyboard Work on Desktop but Not in Chromium?
Not all applications automatically trigger the on-screen keyboard. In testing, Chromium on Bookworm required manual activation via the top panel icon even when squeekboard was enabled. Click the keyboard icon in the top panel to force it open.
Can I Add a Taskbar Toggle Button for Quick Access?
Yes. Create a bash script at /usr/bin/toggle-keyboard.sh that kills or starts the keyboard process, then add a .desktop file and modify the lxpanel configuration to include a launch button. After reboot, a keyboard icon appears in the top-right taskbar for toggling.
Does the On-Screen Keyboard Work on Raspberry Pi Zero 2 W?
Yes, but performance depends on the OS version. Pi Zero 2 W typically runs older X11-based OS, so matchbox-keyboard is the stable choice. However, it consumes more CPU than wvkbd, so monitor system load during robotics projects.
What's the Best Keyboard for Large Touchscreens (10+ Inches)?
For 10-inch displays like the SunFounder DIY Touchscreen, wvkbd-mobintl with the -L 280 flag provides optimal key height and spacing. The -L flag sets keyboard height in pixels, making keys finger-friendly on large screens.