I'm looking for a solution for configuring wifi in headless mode, the same way as IoT devices : when not known wifi in range, toggle to AP mode with a predefined SSID, run a small web-server to list available network, and provide inputs to enter network Key.

I didn't find anything, so I'm eager to develop something to solve the problem.

So does someone know a premade solution ? If not, how should I proceed ? Write a script that modifies wicd/wpasupplicant config files ?

4 Answers 4


The google coder project does exactly this and I've used it successfully to enter wifi credentials and connect a headless Raspi to a wireless network.

  • copy the coder image to an SD card.

  • Connect to the headless Raspi via a web browser on another computer. The computer must be on the same network as the Raspi.

  • To access your Coder, allow time for it to boot, then visit http://coder.local on your computer.

  • The Raspi, booted with the coder image, starts a web server and after logging into the site a password can be entered to connect to any detected SSID on the next boot.


This might be interesting:


The app is not 100% stable. I still have some problems as described in issue #12.

  • 1
    Have to try, but it seems to do the job ! Since I ask the question, another project came to life : github.com/resin-io/resin-wifi-connect a module from resin.io framework
    – Tryum
    Mar 23, 2016 at 14:48
  • many thanks for the link, this sounds really interesting. I will try to install it on my pi :-) Mar 24, 2016 at 16:33
  • I have tested resin-wifi-connect. It requires to download a resin.io image and is not exactly what I was looking for. Mar 28, 2016 at 21:54
  • It can't be used as a standalone tool ? what a shame :/
    – Tryum
    Mar 29, 2016 at 13:02
  • I could not use it as a standalone tool. I had to enter my wifi credentials on the resin.io website before downloading the image. Yesterday I found this repository on Github: github.com/jasbur/RaspiWiFi It might be an alternative. I haven't tested it yet. Mar 30, 2016 at 19:37

Simple and easy working solution.


  • I wish you would read about Markdown formatting, and use it in your posts. :)
    – Seamus
    Apr 21, 2021 at 21:24
  • "In most cases, a plain URL will be recognized as such and automatically linked:" .. "To create fancier links, use Markdown:" I have just registered quickly to share my conclusion and help others. I don't want fancy links. I wish you would be less cynical. :)
    – user132771
    Apr 23, 2021 at 10:03
  • Cynical?! If I'd said anything cynical in my comment, I would apologize for it. But I won't apologize for being insulted by you - someone who won't even bother to learn the meaning of a word before insulting someone who is trying to inform you.
    – Seamus
    Apr 23, 2021 at 22:16

If you want to setup an IoT like network; it will be very painful (a loads of work has to do to make it automate).

For your question I want to share what I have done for automatic network connection. You will have to develop a mobile app (in my case it was android).

First, I gave each device a name and a psk. Then run an encryption on the name and get the generated SSID. Then configure this SSID through wpa_supplicant or hostapd.

base_64(encrypt(ssid + 'delimiter' + psk)) ==> your hostapd/wpa_supplicant ssid

In you android app get the scan list run decryption on the name (only your devices will succeed others will fail). extract SSID and psk. configure wpa_supplicant using the SSID and key.

network_info = split(decrypt(base_64(scan_list)), 'delimiter')
ssid = network_info[0]
psk = network_info[1]

hope this helps :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.