I have been using my ESP8266 module with my Arduino on my university's Wi-Fi network, which only requires a password to log on to.

The university will soon terminate that Wi-Fi network and replace it with one that requires a username and password to log on.

What would that AT command be to connect to such a network?

Edit: I have since found out that the university has changed the network so that a user can "connect" to the network and then enter their university id/password in a captive portal to gain internet access (and perhaps other features of the network). Also, I have since learned how to overwrite the firmware on my esp-01 so that I no longer need to use the AT commands -- in fact, I can program it in the Arduino IDE just as I would with another esp8266-based device, such as the NodeMCU.

  • sounds like you'll need WPA2/Enterprise - read this and this - though I'm not sure if the latest AT firmware has any support - but I haven't read those links too much Jul 23, 2016 at 2:40
  • Get a wifi router, and make a local "development" network. (If you don't need internet on the ESP8266)
    – Paul
    Nov 27, 2016 at 21:34

2 Answers 2


We can't tell without more information but it sounds rather like you will need a [WiFi_SSID, WiFi_PASSWORD] pair for the ESP to connect to the WiFi, and a [Network_USERNAME, Network_USERPASSWORD] pair for their network to let you use the network (as if you were logging onto it by hand from a terminal).

If so, you'd provide the first pair as you do now, with the AT+CWJAP... command, to get your device connected to the WiFi. For the second pair, your Arduino will probably need to interact with a user logon screen to provide the second pair. You'll need to get those details from the school's IT department, and possibly mimic a terminal.

Update: As above, you need to find out whether the network requires 2 sets of credentials - the SSID and WPA2 key and network username and password. If it requires the latter, then your ESP can get you onto the WiFi but your Arduino will then have to mimic a user sitting at a terminal - read the network ID and Password challenges and provide the appropriate responses. Without know that, you can't know how to write the login code, nor can we. It sounds as if there are people on site who have already done what you're trying to do. They and their experience can be far more helpful than we, who have no knowledge of the school network.

  • The network will be WPA2 secured. When logging on with my Windows 10 PC, I am prompted to enter credentials in a web browser. When using the ESP8266, might I need to send an HTTP request to the AP containing login credentials?
    – pnn001
    Jul 22, 2016 at 18:25
  • That seems at least possible. We really don't know enough yet to do more than guess.
    – JRobert
    Jul 22, 2016 at 18:48
  • I'm using an ESP-01, interfacing with it using softser. The network is WPA2 secured, which is supported by the ESP8266. I will have to connect to Eduroam to use the network.
    – pnn001
    Jul 23, 2016 at 23:51
  • I did not understand the changes to the network at the time. To the best of my knowledge, the network is WPA2 secured. To gain internet access, users must now enter credentials in a captive portal. I don't know how, but others at my school have been able to navigate this using a NodeMCU programmed in the Arduino IDE.
    – pnn001
    Jun 10, 2017 at 18:42

If you are using Arduino+ESP8266 version 1(ESP-01)module. You can connect ESP module to the internet, using AT commands as follows:

Normally, AT+CWJAP="ssid","password"

If your Internet requires ssid, username and passowrd(usually in universities- eduroam) then

1) Connect to eduroam or university wifi using ssid, username and password from your laptop.

2) Install Connectify Hotspot software in your laptop.

3) Open "Connectify Hotspot" application and open settings tab, then create wifi-hotspot.

4) Give eduroam(or your wifi)-->"Internet to share" field , Give your own Hotspot name and password. Then click on "start Hotspot" button.

5) Now your esp01 module can detect this new hotspot using AT+CWLAP. Connect to
it using AT+CWJAP="HOtspot ssid","HOtspot password".

This way you can overcome the problem of extra Authentication.

Hope it helped. Enjoy Programming.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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