Wemos D1 Mini Setup

Wemos D1 Mini SetupWith an easy setup and the familiar Arduino IDE for programming, this could just be my new favourite device.

If you own an Arduino but haven’t bought yourself a Wemos D1 Mini yet – you should. I know a lot of these new/different boards can intimidate us average makers, but this one sits on the ‘not scary’ list.

The D1 Mini has a really simple setup and uses development environments and code languages that should be familiar to any Arduino user. I bought one back in December as yet another unnecessary purchase (my last post was about another!). I wasn’t sure what it was, but for £8 I didn’t really care (“gear whore gear whore!”).

Anyway, new board = new territory, so I had to learn how to get this thing running. Here’s how I did it…

Need a Wemos?

The older V1 board is available at Amazon.

The newer V3 is available at RasPiO (this is where I purchased mine)

If you’re not fussed about waiting a month+ for delivery, China stores like AliExpress will have plenty.

What’s a Wemos D1 Mini?

Before we start touching this thing, we should probably get to know it first. A bit like dating.

After some light research, I discovered that the Wemos D1 Mini is an Arduino compatible ESP8266(EX)-based board, busting out 11 digital input/output pins and a single analog input pin.

It offers the convenience of a micro-USB connection for both power and data (running at 3.3V), and despite its size has built-in WiFi and 4MB of flash memory.

Not bad for a couple of nuggets short of a cheeky tenner.

Wemos D1 Mini front and rear

Compact: The Wemos D1 Mini is a neat little package with a decent list of features

Setting up the Wemos D1 Mini & Arduino IDE

So the goal here is to get this thing working like an Arduino i.e. connected to your PC, showing a COM port, loaded into the Arduino IDE and running the famous blink sketch.

I’m a Windows user (Windows 10), so that’s what this guide is based on (suck it up Linux people, you know Windows is king):

Install the Drivers

For the D1 Mini, here is where you download the driver: https://www.wemos.cc/en/latest/ch340_driver.html

If you get some weird ‘install failed’ message, try clicking the ‘uninstall’ button first, then go for the install again – worked for me.

Wemos D1 Mini Driver Install Window

Hit the uninstall button if you get any failure messages

Install the Arduino IDE

I don’t have to walk you through this one – download and install the Arduino IDE if you don’t already have it: https://www.arduino.cc/en/Main/Software

Install the ESP8266 Board Manager

We’re going to add a new bunch of boards into the Arduino IDE board manager, as the Wemos isn’t in there by default.

In the Arduino IDE, go to File > Preferences. A window will pop up, and at the bottom is a field called ‘Additional Boards Manager URLs‘.

Simply copy and paste the following into that field, then press OK:


Arduino IDE preferences window

Simply copy and paste the highlighted text into the same field in your IDE preferences window

Install the ESP8266 Library

Now we need to install the library for our Wemos.

Go to Sketch > Include Library > Manage Libraries, then in the search box enter ‘ESP8266 Platform‘.

You want to install the library called ‘ESP8266 Microgear‘ (which I’ve just noticed is by someone called ‘Chavee’. I’ve been called chavvy a few times over the years)

ESP8266 Microgear library window

Make sure you select the Microgear option

Install the Board

Next we install the boards so that they show up in the tools menu alongside the Arduinos etc.

Go to Tools > Board > Boards Manager, then search for ‘ESP8266‘.

Install the ESP8266 option (should be the only one there):

ESp8266 Board Manager window

There should only be one option to install. Easy!

Connect & Select the Wemos

Plug your Wemos in to a USB port on your PC (make sure it’s a proper data cable, and not some nasty power-only crapper).

Now we need to tell the Arduino IDE which board we’re using. Select Tools > Boards > WeMos D1 R2 & Mini.

You’ll notice a load of new options appear such as ‘Flash Size’, ‘CPU Frequency’, ‘Upload Speed’ etc – ignore all of these (for the Wemos D1 mini at least). All you need to do is ensure your Wemos COM port is selected:

Arduino IDE COM port selection

Distractions: Ignore everything else, just make sure you have the right COM port selected.

Load the Blink Sketch

We’re going to upload the mighty ‘blink’ sketch to test that the Wemos is talking to everything properly, and is able to accept a sketch.

The Wemos D1 Mini has an on-board LED (trust me, it’s there) so no components are required here.

Load the blink sketch by selecting File > Examples > ESP8266 > Blink. The IDE window should load something like this:

Wemos D1 Mini Blink Sketch

You can’t beat the humble Blink sketch for testing your board

Now hit the ‘Upload’ button on the Arduino IDE (circle button with a right-arrow), wait 10-seconds or so, then enjoy the magic that is the blink sketch:

Wemos Blink Sketch LED

Relish the satisfaction from lighting that tiny LED!

There you have it folks, your Wemos D1 Mini is up and running. We’ve got it set up, talking to your PC and running a sketch.

What you do next is up to you…


14 Comments on "Wemos D1 Mini Setup"

  1. Hello, I have D1 mini. I have no problem to flah them. But, when I power off (USB use off), I have to flash again… program is no more there when I power off and power on.
    Is it normal ?
    Thank in advance for your information.
    Regards Luc
    (I followed parametrisation above)

    • That seems very odd. The program should store and run every time you power the board. I’ve not come across that before with the Wemos, Arduino or any board that uses the Arduino IDE. Do you have the board selection settings correct? (Don’t forget there are variations – D1 Minis, D1 Mini Lites etC)

  2. celestica | 21/01/2019 at 17:23 | Reply

    thanks for a great tutorial id spent a couple of hours getting to know my wemos d1 and yours was the one that worked much appreciated

  3. Hello!
    First I would like to thank you for your guidance as Im a newbie 🙂
    I am having a little problem once I search for ESP8266 (Install the Board) to add my D1 mini.
    Nowhere from the list is showing the one from your screenshot.

    • That’s odd – have you definitely installed the library (ESP8266 Microgear), and did you try closing down the IDE and restarting it before adding the board? Are you definitely in the boards manager when you try this (the boards manager and library manager look very similar – I find myself in the wrong place a lot).

  4. Christo de Beer | 04/04/2019 at 07:23 | Reply

    Hi thanks

  5. this is best guide for Wemos D1 mini and Arduino IDE on the net! thanks! (my computer told me it installed the drivers automatically… but it lied. thanks for the drivers link)

  6. And… if you know Python, but are new to C you can install and run MicroPython on your D1.
    Some instructions:
    A very cool development board.

  7. Hi,
    Thanks a lot for your detailed steps. I’m new to this IOT things. Just ordered Wemos D1 mini v.3.0.0 and DHT22 shield board to built my smart temp/humi sensor. This is a very good starting guide.
    Thanks again.

  8. Sohail Anwar | 28/09/2019 at 12:10 | Reply

    Hey Admin,
    I have issue with my WeMos D1 R2 when I am uploading blink sketch it works well but when I am trying it for communication over Server it does not work. Do I have to do AT command flash? if yes how can I?
    Please Guide me

  9. https://wiki.wemos.cc/downloads this link didnt work for us however we found that this link: https://www.wemos.cc/en/latest/ch340_driver.html did, if you could correct that we’d really appreciate it.

  10. Duncan Bayne | 25/09/2020 at 03:19 | Reply

    Hi Thanks for this.
    I am building an ispindel ( for monitoring beer ferment and temp ). Uses wemos d1 mini
    My version I want sealed ( for several reasons ) but would like to still be able to trigger a reset.

    Can I attach a reed switch into the little holes on the other side of the reset switch ( would this be 2 switches in parallel?) . Is that ok?
    Does it need to be always on and turned off to reset, or vice versa?
    Thanks duncan

Leave a comment

Your email address will not be published.


This website uses cookies. Please visit our privacy policy page for more information. Privacy policy

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.