Tested on:RPi3; Raspbian Stretch
Prerequisites:Raspberry Pi with Raspbian Jessie and internet connection (see steps 1-7 in the Introduction)

Update: Autostart Chromium for full screen applications

HTML interfaces are neat for controlling a Raspberry Pi, but require loading a website in a browser like Chromium in full screen after
boot (kiosk mode). Since the last update, the description in the tutorial Chromium Autostart work no more. Instead, here’s an easy way for
enabling kiosk mode via rc.local.

Autostart Chromium with rc.local
Open the file with

and add before the line

the following

Now, Chromium starts automatically in kiosk mode after booting and opens a website, here localhost for a remote control.

Tutorial CherryPy for HTML interfaces: http://www.knight-of-pi.org/cherrypy-an-elegant-python-webserver-for-raspberry-pi-remote-controls/
Chromium Autostart (deprecated): http://www.knight-of-pi.org/autostart-chromium-60-in-kiosk-mode-for-raspberry-pi-remote-controls/

Knight of Pi

Johannes Bergs aka Knight of Pi. Diploma in Bioinformatics, some Webdesign and Python coding then. Living in the beautiful city of Vienna.


  1. Problems:
    1) Chromium browser displays message that it is not the default browser. Not good in kiosk situation. No one there to close the message.
    2) also displays the warning message about security when no sandbox option is used. Again, not good in kiosk situation.
    3) browser or pi blanks the screen after so many minutes of no user activity. I found a chromium command line switch “—user-activity-timeout=0” but it did not seem to change anything. Again, not good in a kiosk situation for displaying a continuous web page.
    4) exiting browser now leaves me without the xwindows active. Just drops me to terminal mode.

    So still struggling with this method.

    • Hello David!

      Really, Chromium kiosk mode has made me quite a few headaches. Every new release changes some of the startup behaviour and it’s documented only if you’re lucky. 1) and 2) weren’t a problem with older chromium versions, so installing an older version of chromium might be a nasty, temporary fix.
      3) is not related to the browser, that’s standard Raspbian screen timeout, you can google that, easy to fix.
      4) Is interesting, never experienced that.



  2. Hi, when i use this line (xinit …..&) on a 4k screen on a Pi4, it only fills one quarter of the screen.
    Is there a command that resizes the screen back to normal?
    I don’t want to use the 3840×2160 resolution as the screen update is quite slow on pi4. I want to run the 1920×1080 instead,

    • Hey Peter,
      i can’t replicate that because i do not have a Pi4 and a 4k screen. Chromium offers a flag –window-size “800,600”, you can try if that helps.

  3. Is there any way to get the page to refresh from the autostart file without having to point it to a script?

    • Installed chromium extension Super Auto Refresh Plus and set the auto start file to not be incognito and it worked like a charm.
      Edited this file: sudo nano /etc/xdg/lxsession/LXDE-pi/autostart

      @lxpanel –profile LXDE-pi
      @pcmanfm –desktop –profile LXDE-pi
      @xscreensaver -no-splash


      # Enable mixed http/https content, remember if invalid certs were allowed (ie self signed certs)
      @sed -i ‘s/”exited_cleanly”: false/”exited_cleanly”: true/’ ~/.config/chromium/$
      @/usr/bin/chromium-browser –start-maximized –kiosk –noerrdialogs –allow-running-insecure-content –remember-cert-error-decisions –disable-restore-session-state –disable-infobars http://web/addess/here
      @xset s off
      @xset s noblank
      @xset -dpms
      # Refresh

      # END ADDED

  4. I have tried this and it doesn’t open the page I want, it always open the welcome to Chrome page and
    Also its shows a No–sandbox is not secure
    It doesn’t keep the settings I set in Chromium.
    Any Ideas

    • Hey Paul,

      if you’re only building a RPi device for displaying a website with no other web interaction, you can ignore the safety warning.
      In the command above, i open localhost to display a HTML remote control. If you want to show some website instead, you need to replace http://localhost:8080 with the website of your choice.

  5. Been playing with a lot of scripts to get something simple as this running..
    This just works like a charm, thanks a bunch :)

  6. ehmmmm,
    Works good, but when I enable Chromium autostart, it starts but I loose connection to X11VNC. I cannot connect to it. Any clues? Its something with xinit but at the moment I dont know what.

  7. Hi,

    Do you have any tips on disabling the screensaver when running this through rc.local?



Time limit is exhausted. Please reload CAPTCHA.