Introduction: Connecting an LCD to the Arduino

Picture of Connecting an LCD to the Arduino
In this instructable we’ll be looking at how to connect a parallel LCD to an Arduino. The LCD that I am using uses the common HD44780 interface.  Many LCDs have this, you can usually tell by the 16-pin interface. You only need to solder 10 of the 16 wires to use the LCD, but this will only enable you to use the 4-bit interface.
Arduino (with USB cable)
HD44780-compatible LCD screen
10 Jumper wires

1 10k Potentiometer
Soldering Iron
Helping Hands (optional)
Let’s get started!

Step 1: Connecting the Jumper Wires

Picture of Connecting the Jumper Wires

     The first step we need to do is connect the pins to the LCD.  For those interested, you can find the datasheet here.
     I got my LCD from sparkfun, and you can buy one here.
As I mentioned before, you only need to connect 10 pins.  Solder jumpers to these wires:

Pin 1 - Ground
Pin 2 - +5V
Pin 3 - Contrast Adjustment
Pin 4 - H/L Register Select
Pin 5 - H/L Read/Write
Pin 6 - H/L Enable
Pin 11 - DB4
Pin 12 - DB5
Pin 13 - DB6
Pin 14 - DB7

As shown in the picture below:

Pin 1 to GND
Pin 2 to 5V
Pin 3 to wiper
Pin 4 to Arduino pin 12
Pin 5 to GND
Pin 6 to Arduino pin 11
Pin 11 to Arduino pin 5 
Pin 12 to pin 4
Pin 13 to pin 3
Pin 14 to pin 2

Because we will only be writing, pin 5 will be dropped to ground to show that there will be no reading.  For those who wish to use the backlight, connect LCD pin 16 to GND and LCD pin 15 to +4.2V. 

Connect one side of the pot to GND, the opposite to +5v, and the center to LCD pin 3.  Now you're in business.


Step 2: Opening the IDE

Picture of Opening the IDE

Now, you need to open up the Arduino IDE. (For those who are lost click on the icon!)  Then click File -> Examples -> LiquidCrystal -> HelloWorld.  Open the sketch and dowload it to the Arduino board.

     You can change the text if you want.

Step 3: Mission Complete

Picture of Mission Complete

Your done!  You can substitute text for variables, or even analogRead().  In this way you can read in sensor values and such.

Thanks for reading my instructable!   Please Comment and Rate.


grbank5428 made it! (author)2018-01-03

does any one have the code for the ultra sonic sensor, and display for the arduino atmel 328 surface mount board. i have tried to download the right library but is having problems.

CIClubPhys made it! (author)2017-04-15

Worked as instructed on my Pro Mini!

rockerrock121 (author)2017-03-08

how do i copy the text???????

Canters made it! (author)2016-12-29

Thanks for simple and clear explanation. Took me about 15mins. :)

beatniksailor made it! (author)2016-09-26

I loved it. I made(MAKDED:) a few mods using a arduino NANO w/pinouts and a small b-board, I soldered jumpers to lcd and left the pins long to plug into the b-board. I hope to take advantage of unused pin & board space to add sensors & some communication stuff!! THNX!!

John JoshuaR1 (author)2015-09-26

is it possible to hookup the arduino and LCD without using potentiometer??

Georgeh3 (author)John JoshuaR12015-12-26

If you know the value you need I suppose you could use a resistor.

KhubaibK1 (author)Georgeh32016-08-12

yes u can by using LCD module by ardinu which is easy to use .you just attach those pins with ardino that have to be use in your program and ither advantage is that that module is fixed on ardinu completely

Dashing Rainbow Dash (author)2016-03-13

Can I change what pins to connect the LCD to? I need pin 2 for an interrupt.

DyanD1 (author)2015-11-24

Do you know how to connect an arduino mega 2560 R3 to 4x20 LCD??

SumithB (author)2015-09-17

no err. great

ShauryaS3 (author)2015-07-04

how to change pins as pro mini has only 10 digital pins?
please reply soon project deadline tommorow

SelvaK3 (author)2015-05-14

I like your project and I will give 5 star

azhween (author)2015-03-07

i need a program for interfacing lcd wit arduino atmega 328 with y=mx+c logic . please help me out

The.Deathspace (author)2015-03-05

Sir I want to know if you can change the pin initialization of the LCD and what other pins can i used to initialize it ( I'm using pin 2 as an interrupt thats why I need to reinitialize it to other pins)

rohanjoseph (author)2015-02-17

hello...i did what was instructed on my 16*2 LCD but after running the code all it shows is black boxes...plz help!!

Are you using the 10k Potentiometer? That is what you need to adjust the contrast so you will be able to see the text. Check connections if you are using it.

pallaviv (author)2015-02-20

ii this is pallavi valunj i want to write code to display the robot moving left and right on display pl help me in this

ibenkos (author)2014-10-26

Check my instructables out to uppgrade your work on a shield

borigam.tejaswini (author)2014-10-12

please send me ...this total copy to my

Volthaus Electronics Laboratory made it! (author)2014-08-28

I just finished soldering a 16 pin header on my new LCD screen and did a quick search for an Instructable I could use to test my work and your project came up. I grabbed my Arduino, jumpers, and a 10k pot and whipped it up. Thanks!

drebollo (author)2014-08-07

Check mine about 3.2" 320x240 TFT LCD screen ;)

Niveditanive (author)2014-03-13

can i get a code for displaying 12 images in a LCD TFT touchscreen ??????

jdoeson (author)2013-05-28

Awesome instructable!

I was able to get everything running smoothly on my ATmega328 (Arduino Uno) and a TM204A-1 LCD screen I got from Amazon. I thought I would be spending days learning how to figure this out, but after soldering the DIP pins on the LCD I was able to get this up in 30 minutes!

I made a slight adjustment by connecting pins 15 and 16 as "The nerdling" mentioned, in order to get the backlight working. I connected pin 15 of the LCD to pin 13 on my Arduino, and made sure to open the pin (13) via IDE programming. Naturally, pin 16 went to the same ground as the rest.

I also used a mini breadboard for the LCD (the red one) to make things easier.

See the attached photo for my setup.

monsur (author)jdoeson2014-02-04

Hi, I have followed the following configuration and can see my message on the screen, vaguley (

You have mentioned opening pin 13 on the IDE, how is this done?

monsur (author)2014-02-04

I am using an arduino pro mini and have followed the following link to get the message to display on my 16*2 LCD. (

I have managed to upload it with no problem but cannot seem to clearly see the writing that is visible, it is very dim and cannot understand why. The issue may be related to my 10k potentiometer as it does not adjust when I turn it.

From the uploaded pic you can just make out ' Hello World' on the top and '' on the bottom.

Any suggestions?

dalbyman (author)2014-01-23

Thankyou for posting this informative instructible.

Had everything working within 30 mins - Brilliant.

FYI - I found that connecting pin 15 on the LCD to the 3.3v pin on the Arduino powered the back-light fine.

micaiah12 (author)2013-11-05

Help all I am getting is white boxes on my 20x4 white on blue LCD.

I set it up exactly like the picture and instructions. I even added
pin 15 = Digital Pin 13
pin 16 = GND
to light up the backlight.
Why won't it work?

us241098 (author)2013-06-17

Hi crocboy!!! I connected my lcd same way as in your instructables and it works.
now i am facing a problem i am newbie to arduino and want to use lcd as output ( actually i want to print different numbers when different tactical switches are pressed ) please help me.

crocboy (author)us2410982013-06-21

You'll have to do that all in your code. Read in from the digital inputs on the Arduino and set the text in your display to reflect the state of the switches.

axpence (author)2013-06-10

note: when the user put %v, he means +5V

crocboy (author)axpence2013-06-21

Thanks for catching that, I'll change it

irtiq7 (author)2012-08-05

Hi there,

I tried everything but I am still getting those black boxes when I set my potentiometer high.

waterlubber (author)irtiq72012-08-12

Just replace that pot with a simple wire to ground. Works for me!
(P.S. The boxes are GOOD, its supposed to happen)

coder512 (author)2011-11-11

What do you mean by the wiper part , i didn't get that !!
Pin 3 to wiper ?????

Michael_Bell (author)coder5122012-04-30

the middle pin of your potentometer

Connect either end to +5v and ground, and wiper will be the middle pin

Jeff_ (author)2011-12-04

followed the guide and i only get some weird signs on it but no hello world

crocboy (author)Jeff_2011-12-30

recheck your pin connections, that's usually the main cause of this issue.

prateekk (author)2011-07-03

hi ! can u plz tell me the link to the software with the help of which i can boot a programe/code into my arduino...??
like i hav avr for atmel micro controllers.
plz help!!

crocboy (author)prateekk2011-08-19

To upload code to the Arduino, use the Arduino IDE:

andy70707 (author)2010-10-07

Thanks, great instructable, I just got my arduino today and this was my first project!

The nerdling (author)andy707072011-05-03

ardino's are awesome your rate of fun projects will go up by the hundreds

anselmi (author)2010-10-07

i wired mine just like this and the lcd wont light up or show any thing
if any one could help me i would really appreciate it

The nerdling (author)anselmi2011-05-03

have you connected the enable pin to 5v or gnd or pin 5?

The nerdling (author)2011-05-03

everyone pin 15 and 16 are the backlight pins.
i connected them into 5v with a 140Ω resistor
if your wondering how i got the ohm sighn i used character map in windows

heleniovix (author)2011-04-06

i will try in proto-board.

Robot Lover (author)2010-09-27

I set it up right but all i get are boxes. What should i do?

crocboy (author)Robot Lover2010-11-19

For the people getting black boxes, you may want to try adjusting the contrast potentiometer.

Derin (author)2010-05-15

Help! I did all you said but I only get black boxes on the LCD. What should I do?

frollard (author)2010-03-09

May I recommend hooking the backlight led to a pwm pin via a resistor, or with a protection resistor via a transistor (if the backlight pulls too much current for the atmega pin to handle).  Variable brightness ftw!

Good writeup!

About This Instructable




Bio: I love to build stuff.
More by crocboy:Paracord Ladder w/ Wooden RungsUsing WiiChuck Adapter with ArduinoConnecting an LCD to the Arduino
Add instructable to: