Free shipping €150+
Blog/tutorials

Nextion Display Complete Programming Guide: Master the Nextion Editor in 2025

Complete Nextion Editor tutorial for beginners. Learn to program Nextion HMI displays, create stunning interfaces, and master GUI design with step-by-step examples.

Robotics3D TeamJanuary 15, 202512 min read
Industrial HMI touchscreen display
Nextion displays are used in industrial HMI applications. Image: Wikimedia Commons (CC-BY-SA)

What is Nextion Editor?

Nextion Editor is the official free software for designing user interfaces for Nextion HMI displays. It's a WYSIWYG (What You See Is What You Get) editor that lets you create professional touchscreen interfaces without complex programming.

Nextion Editor Features

  • Drag-and-drop interface design
  • Real-time simulator preview
  • Event-driven programming
  • Image and font import
  • One-click upload to display

Installation

  1. Download Nextion Editor from nextion.tech
  2. Run the installer (Windows only, use Wine on Mac/Linux)
  3. Launch Nextion Editor from Start menu
  4. Create a new project and select your display model

Editor Interface

GUI design software interface
GUI design interfaces share common elements with Nextion Editor. Image: Wikimedia Commons
Panel Purpose
ToolboxUI components (buttons, text, gauges, sliders)
CanvasDesign area matching your display size
Page ListManage multiple screens/pages
AttributesProperties of selected component
EventsCode for touch/release/timer events
OutputCompilation messages and errors

UI Components

Touchscreen control panel
Touchscreen panels in industrial applications. Image: Wikimedia Commons

Basic Components

  • Text (t0, t1...) - Static or dynamic text labels
  • Number (n0, n1...) - Numeric values with formatting
  • Button (b0, b1...) - Clickable buttons with states
  • Picture (p0, p1...) - Image display from memory
  • Crop (q0, q1...) - Partial image display

Advanced Components

  • Progress Bar (j0) - Horizontal/vertical progress
  • Gauge (z0) - Circular meter display
  • Slider (h0) - User-adjustable value input
  • Waveform (s0) - Real-time data plotting
  • Timer (tm0) - Periodic code execution

Nextion Instruction Set

Nextion uses a simple instruction set. Here are the most common commands:

// Change text
t0.txt="Hello World"

// Change number value
n0.val=123

// Change component color
t0.pco=RED // or use number: t0.pco=63488

// Navigate to another page
page 1 // or: page pagename

// Send data to MCU
print "data"
printh 65 01 02 03 // hex values

// Variables
va0.val=100
sys0=50 // system variable

// Conditional
if(bt0.val==1) {
 t0.txt="ON"
} else {
 t0.txt="OFF"
}

Display Models

LCD display sizes
Nextion displays come in various sizes from 2.4" to 7". Image: Wikimedia Commons
Series Features Best For
BasicResistive touch, 256 colorsHobbyist projects
DiscoveryResistive, GPIO pinsSimple HMI
EnhancedMore RAM, RTC, GPIOProfessional
IntelligentCapacitive touch, 65K colorsIndustrial

Arduino Integration

Wiring (5V tolerant)

  • Nextion TX → Arduino RX (pin 0 or SoftwareSerial)
  • Nextion RX → Arduino TX (pin 1 or SoftwareSerial)
  • Nextion 5V → Arduino 5V
  • Nextion GND → Arduino GND
#include <SoftwareSerial.h>

SoftwareSerial nextion(2, 3); // RX, TX

void setup() {
 nextion.begin(9600);
 delay(500);
 // Set text on display
 nextion.print("t0.txt=\"Hello\"");
 nextion.write(0xFF);
 nextion.write(0xFF);
 nextion.write(0xFF);
}

void loop() {
 // Read touch events
 if (nextion.available()) {
 // Handle incoming data
 }
}

Nextion Displays

We're official Nextion distributors for Europe. Browse our full range!

See our Nextion Smart Home Interface project.

Frequently Asked Questions

Do I need programming experience to use the Nextion Editor?

No, the Nextion Editor is designed to be accessible for beginners. While programming experience helps with advanced features, you can create functional interfaces using the drag-and-drop interface and simple commands. The event-based system is much simpler than traditional GUI programming.

Can I use custom fonts in my Nextion project?

Yes, the Nextion Editor allows you to import TrueType fonts (.ttf). Go to Tools > Font Generator, import your font file, select the characters you need, and generate the font. Remember that fonts consume memory, so only include necessary characters and sizes.

What is the difference between Basic, Enhanced, and Intelligent Nextion displays?

Basic series are entry-level with core HMI features. Enhanced series add GPIO pins, larger flash memory, and RTC functionality - best for most projects. Intelligent series include SD card support, more memory, and enhanced processing for complex applications with extensive graphics or data logging.

How do I upload my compiled TFT file to the Nextion display?

There are two methods: 1) microSD card upload (recommended) - copy the TFT file to a microSD card, insert into the Nextion, power on, it will auto-update; 2) Serial upload - use the Nextion Editor's upload tool to send the file via serial connection, though this is slower for large files.

Can I animate elements on a Nextion display?

Yes, you can create animations using timer components to update component properties at regular intervals, crop images to create sprite-based animations, or use the picture component to cycle through image sequences. While not as smooth as dedicated animation engines, Nextion can produce effective animated effects for HMI applications.

Related Products

Ready to Build?

Get all the components you need for your next project.

Shop Products
Contact1