SIM800L GSM/GPRS Module

View on Amazon
Overview
About SIM800L GSM/GPRS Module
The SIM800L is a quad-band GSM/GPRS module (850/900/1800/1900MHz) designed for SMS, voice, and data communication in IoT and embedded systems.
β‘ Key Features
- Quad-Band GSM Connectivity β Works worldwide on 850/900/1800/1900MHz networks.
- Compact & Low Power β Ideal for battery-powered IoT applications.
- Versatile Communication β Supports SMS, voice calls, and GPRS data transfer.
- Internet-Ready β Built-in TCP/IP, HTTP, FTP, and MMS support for online communication.
π Still choosing a SIM module? Check the ESP32 SIM Modules Comparison Table for a detailed breakdown of LTE, 3G, and GPRS options.
Get Your SIM800L
π‘ Prices are subject to change. We earn from qualifying purchases as an Amazon Associate.
SIM800L Specifications
Complete technical specification details for SIM800L GSM/GPRS Module
π Technical Parameters
SIM800L Pinout
The **SIM800L** is a compact GSM/GPRS module with UART communication:
Visual Pinout Diagram

Pin Types
Quick Tips
**GSM Bands**: Quad-band 850/900/1800/1900MHz,β‘ **Power**: 3.4V-4.4V (use dedicated power supply!),π **Interface**: UART (typically 9600 or 115200 baud)
**Current**: Peak 2A during transmission,πΆ **Antenna**: External antenna required on NET pad,π³ **SIM Card**: Nano-SIM or adapter needed
**Features**: Voice calls, SMS, GPRS data,π **Protocols**: TCP/IP, HTTP, FTP, MMS,π― **Applications**: IoT, SMS alerts, remote monitoring
Pin Descriptions
| Pin Name | Type | Description | Notes |
|---|---|---|---|
1 VCC | Power | Power input | 3.4V to 4.4V (NOT 5V tolerant!) |
2 GND | Power | Ground connection | |
3 TXD | Communication | UART transmit | Sends data from module (connect to ESP32 RX) |
4 RXD | Communication | UART receive | Receives commands (connect to ESP32 TX) |
5 RST | Control | Reset pin | Active low reset |
6 NET | Control | Network status indicator | External antenna connection pad |
Wiring SIM800L to ESP32
To interface the **SIM800L** with an **ESP32** via UART:
Visual Wiring Diagram

Connection Status
Protocol
Pin Connections
| SIM800L Pin | Connection | ESP32 Pin | Description |
|---|---|---|---|
1 VCC Required | External 4V | Stable power supply (NOT from ESP32!) | |
2 GND Required | GND | Ground (shared with ESP32) | |
3 TXD Required | GPIO16 (RX2) | Module transmit to ESP32 receive | |
4 RXD Required | GPIO17 (TX2) | Module receive from ESP32 transmit | |
5 RST Optional | GPIO5 | Reset control (optional) | |
6 NET Required | External Antenna | GSM antenna connection |
**Power Warning**: SIM800L requires 3.4-4.4V with 2A peak current - do NOT power from ESP32!
**Power Supply**: Use dedicated power supply or LiPo battery (3.7V) with large capacitors (100Β΅F + 1000Β΅F)
**Baud Rate**: Default 9600 or 115200 bps (check module specs)
**TX/RX**: Connect module TXD to ESP32 RX, module RXD to ESP32 TX
**Antenna**: External GSM antenna is mandatory for reliable operation
**SIM Card**: Insert nano-SIM with PIN disabled
**Voltage Drop**: Use thick wires (22AWG) and low-ESR capacitors
**AT Commands**: Control via AT command set
SIM800L Troubleshooting
Common issues and solutions to help you get your sensor working
Common Issues
Issue: The SIM800L module restarts frequently, indicated by the status LED turning off and on repeatedly.
Possible causes include insufficient power supply or voltage drops due to wiring.
Solution: Use a dedicated power supply capable of providing 4V and at least 2A. Incorporate low ESR capacitors (e.g., 100Β΅F tantalum and 470Β΅F electrolytic) close to the module's power pins to handle current spikes. Additionally, use short, thick wires (e.g., 22AWG) to minimize resistance and ensure consistent voltage levels.
Issue: The module's network LED blinks rapidly, indicating it is not registered on the network.
Possible causes include incorrect SIM card configuration, poor signal strength, or frequency mismatch.
Solution: Ensure the SIM card is active, has sufficient balance, and the PIN lock is disabled. Check the external antenna connection and position it in a location with better network coverage. Verify that the module supports the cellular network's frequency bands in your region.
Issue: No response from the module when sending AT commands.
Possible causes include incorrect baud rate, wiring errors, or power instability.
Solution: Ensure that the module and the microcontroller are set to the same baud rate (default is 9600). Confirm the RX and TX pins are connected correctly (RX to TX and TX to RX). Use a stable power source and add decoupling capacitors to avoid power fluctuations.
Issue: The SIM800L fails to maintain a stable connection, resulting in dropped calls or intermittent data transmission.
Possible causes include poor antenna placement or interference from nearby electronics.
Solution: Use a proper external antenna and position it away from other electronic components that may cause interference. Ensure that the antenna connection to the NET pin is secure.
Debugging Tips
Use the Serial Monitor to check for error messages and verify the sensor's output. Add debug prints in your code to track the sensor's state.
Use a multimeter to verify voltage levels and check for continuity in your connections. Ensure the power supply is stable and within the sensor's requirements.
Additional Resources
SIM800L Programming Examples
Ready-to-use code examples for different platforms and frameworks
#include <Arduino.h>
// Define baud rate for Serial communication
#define SERIAL_BAUD 115200
#define SIM800_BAUD 9600 // SIM800L default baud rate
// Initialize Serial2 (UART2) on ESP32 (RX=16, TX=17)
HardwareSerial serial2(2);
void setup() {
// Initialize Serial Monitor
Serial.begin(SERIAL_BAUD);
delay(1000); // Small delay to stabilize serial
// Initialize SIM800L Serial (Serial2)
serial2.begin(SIM800_BAUD, SERIAL_8N1, 16, 17); // TX=17, RX=16
delay(1000);
Serial.println("
SIM800 EVB to ESP32 Serial port 2 test");
Serial.println("Sending AT commands to check communication...
");
// Send AT command and check response
sendATCommand("AT"); // Check if module is responding
sendATCommand("AT+CGMI"); // Get manufacturer name
sendATCommand("AT+CGMM"); // Get module model number
sendATCommand("AT+CGMR"); // Get firmware version
sendATCommand("AT+CGSN"); // Get serial number
}
void loop() {
// Read data from SIM800L and print to Serial Monitor
while (serial2.available() > 0) {
Serial.write(serial2.read());
}
// Read data from Serial Monitor and send to SIM800L
while (Serial.available() > 0) {
serial2.write(Serial.read());
}
}
// Function to send AT command and wait for response
void sendATCommand(const char *command) {
Serial.print("Sending: ");
Serial.println(command);
serial2.println(command); // Send command to SIM800L
delay(1000); // Wait for response
// Print response from SIM800L
while (serial2.available()) {
Serial.write(serial2.read());
}
Serial.println("----------------------");
}Serial2 for communication with the SIM800L module. ### **Hardware Serial (UART2)** Unlike SoftwareSerial, which is used on boards like Arduino Uno, ESP32 has dedicated hardware UARTs. This code initializes Serial2 with the correct baud rate and assigns GPIO pins for RX and TX: - serial2.begin(9600, SERIAL_8N1, 16, 17); - Pin 16 (RX) and Pin 17 (TX) are used for UART communication. - The baud rate for SIM800L is set to 9600. ### **Setup Process** 1. Serial.begin(115200); initializes the Serial Monitor for debugging. 2. serial2.begin() initializes communication with SIM800L over hardware serial. 3. The sketch sends a series of AT commands (AT, AT+CGMI, AT+CGMM, AT+CGMR, AT+CGSN) to check the moduleβs response. ### **Loop Function** - Any data received from the SIM800L module is read and printed to the Serial Monitor. - Any input from the Serial Monitor is forwarded to the SIM800L module. ### **Sending AT Commands** A function sendATCommand() is used to send commands and wait for responses: - It prints the command to the Serial Monitor. - Sends the command to the SIM800L module. - Waits for a response and prints it. This sketch allows real-time communication with the SIM800L module through Serial Monitor, making it useful for debugging and testing AT commands.#include <stdio.h>
#include <string.h>
#include "driver/uart.h"
#include "freertos/task.h"
#define TX_PIN 17
#define RX_PIN 16
#define UART_PORT UART_NUM_1
void app_main(void) {
uart_config_t uart_config = {
.baud_rate = 9600,
.data_bits = UART_DATA_8_BITS,
.parity = UART_PARITY_DISABLE,
.stop_bits = UART_STOP_BITS_1,
.flow_ctrl = UART_HW_FLOWCTRL_DISABLE
};
uart_param_config(UART_PORT, &uart_config);
uart_set_pin(UART_PORT, TX_PIN, RX_PIN, UART_PIN_NO_CHANGE, UART_PIN_NO_CHANGE);
uart_driver_install(UART_PORT, 1024, 0, 0, NULL, 0);
char *test_cmd = "AT\r\n";
uart_write_bytes(UART_PORT, test_cmd, strlen(test_cmd));
while (true) {
char data[128];
int len = uart_read_bytes(UART_PORT, data, sizeof(data), 100 / portTICK_PERIOD_MS);
if (len > 0) {
data[len] = '\0';
printf("Response: %s\n", data);
}
vTaskDelay(1000 / portTICK_PERIOD_MS);
}
}uart_read_bytes function in a loop.uart:
baud_rate: 9600
tx_pin: TX
rx_pin: RX
sim800l:
on_sms_received:
- logger.log:
format: "Received '%s' from %s"
args: [ 'message.c_str()', 'sender.c_str()' ]
logger:
baud_rate: 0 # disable uart logger on esp 8266platformio.ini
[env:sim800l]
platform = espressif32
board = esp32dev
framework = arduino
monitor_speed = 115200main.cpp
#include <HardwareSerial.h>
HardwareSerial sim800l(1);
void setup() {
Serial.begin(115200);
sim800l.begin(9600, SERIAL_8N1, 16, 17); // RX, TX
sim800l.println("AT"); // Test AT command
delay(1000);
while (sim800l.available()) {
Serial.write(sim800l.read());
}
}
void loop() {
sim800l.println("AT+CMGF=1"); // Set SMS to text mode
delay(1000);
sim800l.println("AT+CMGS=\"+1234567890\""); // Replace with recipient's number
delay(1000);
sim800l.print("Hello from PlatformIO");
delay(1000);
sim800l.write(26); // CTRL+Z to send SMS
delay(5000);
}from machine import UART
import time
# Initialize UART
uart = UART(2, baudrate=9600, tx=17, rx=16)
def send_at(command):
uart.write(command + '\r\n')
time.sleep(1)
while uart.any():
print(uart.read().decode('utf-8'), end='')
# Test communication
send_at('AT')
# Send SMS
send_at('AT+CMGF=1') # Set SMS to text mode
send_at('AT+CMGS="+1234567890"') # Replace with recipient's number
uart.write("Hello from MicroPython" + chr(26))Wrapping Up SIM800L
The ESP32 SIM800L GSM/GPRS Module is a powerful SIM sensor that offers excellent performance and reliability. With support for multiple development platforms including Arduino, ESP-IDF, ESPHome, PlatformIO, and MicroPython, it's a versatile choice for your IoT projects.
Best Practices
For optimal performance, ensure proper wiring and follow the recommended configuration for your chosen development platform.
Safety First
Always verify power supply requirements and pin connections before powering up your project to avoid potential damage.
Ready to Start Building?
Now that you have all the information you need, it's time to integrate the SIM800L into your ESP32 project and bring your ideas to life!
Explore Alternative Sensors
Looking for alternatives to the SIM800L? Check out these similar sensors that might fit your project needs.

SIM7600G LTE CAT1 Module
The SIM7600G is a versatile LTE CAT1 module that provides reliable communication capabilities for various IoT applications. Its compact...

SIM800A GSM/GPRS Module
The SIM800A is a versatile GSM/GPRS module that provides dual-band connectivity for voice, SMS, and data applications. Its compact design...

A7670 LTE Cat 1 Module
The A7670 is a versatile LTE Cat 1 module that provides reliable communication capabilities for various IoT applications. Its compact...





