Drawing 1 · Interactive
Can she finish the payment before the session drops?
Time since it opened
216s
216s in: window closed. Session dropped: dial the code again.
What is USSD?
Unstructured Supplementary Service Data (USSD) is a GSM service that lets a phone and an application hold a live, menu-driven conversation over the mobile network's signalling channel. The user dials a code that starts with * and ends with #, such as *99#, and the network opens a session: a text menu appears on screen, the user replies with a number, the next menu follows, and so on until the session ends. It works on every GSM handset, including basic feature phones, with no mobile data, app or smartphone.
USSD is not a kind of SMS. SMS is store-and-forward: the operator's SMSC stores a message and delivers it whenever the phone is reachable, and it stays in the inbox. A USSD session is held open in real time while both sides take turns, each screen carries up to 182 characters, nothing is stored on the phone afterwards, and if the user takes too long the network closes the session and they must dial again. Most sessions are started by the user (pull); networks can also start one (push), for example to show a balance after a recharge.
In India the best-known use is NPCI's *99# service, which lets anyone whose mobile number is linked to a bank account make a UPI payment or receive money, check a balance and set a UPI PIN from a feature phone. Operators use codes for balance and plan menus, and banks and cooperatives use them for simple self-service. Businesses reach USSD through operators or aggregators that assign a code and pass each step of the session to an application over HTTP. Because codes can also trigger network features, they have been abused: the Department of Telecommunications suspended USSD-based call forwarding from 15 April 2024 after scams that tricked people into dialling *401# with a fraudster's number.
Key takeaways
- USSD is a live, menu-driven session over the mobile network's signalling channel, started by dialling a code such as *99#.
- It works on any GSM phone, including feature phones, with no mobile data, app or smartphone.
- Unlike store-and-forward SMS, a USSD session is real time: nothing is saved in the inbox and an idle session times out.
- Each screen carries up to 182 characters, so menus must be short, shallow and quick to answer.
- In India NPCI's *99# service lets feature-phone users send money over UPI, check balances and set a UPI PIN.
Operating sequence
How does USSD work?
The user dials a code
Dialling *99# or a service's own code sends a USSD request through the handset's home network. No data connection or app is involved.
The network routes it to an application
The operator's USSD gateway recognises the code and passes the session, with an ID, the caller's number and any input, to the application, directly or through an aggregator.
The application answers with a screen
It returns a menu or prompt of up to 182 characters and says whether the session should continue (expecting a reply) or end.
Turns repeat in real time
The user types an option or a value and presses send; the application replies with the next screen. Each turn must complete before the operator's timeout, or the session drops.
The session closes
A final screen confirms the result, or the timeout ends it. Because nothing is kept on the phone, services usually follow up with an SMS as a record.
Specifications
USSD: key facts and limits
- Code format
- Starts with * or #, ends with #, e.g. *99#
- Screen length
- Up to 182 characters
- Transport
- GSM signalling channel; no mobile data or app
- Session
- Live and turn-based; ends on completion or operator timeout
- Record on the phone
- None (unlike SMS, nothing is stored)
- India example
- *99# by NPCI for UPI payments and banking
- Initiation
- Usually user-started (pull); network push possible
Example: Paying a dealer from a feature phone
A farmer in Sangli buys seed from a local agri-input dealer and pays with *99# on a feature phone. She dials the code, picks Marathi, chooses Send money, enters the dealer's mobile number, the amount and a short remark, then her UPI PIN, and sees a confirmation with a reference number. The first attempt fails because she stops to find the dealer's number and the session times out. The dealer now writes its UPI-linked number on the counter, and sends an SMS receipt for every payment, since the USSD screen disappears once it closes.
Implementation
USSD in code
// Generic aggregator callback: field names vary by provider.// Each POST is one turn of the session; reply fast or the network drops it.app.post("/ussd", express.json(), async (req, res) => {const { session_id, msisdn, input } = req.body;const s = (await sessions.get(session_id)) ?? { step: "start" };let screen;if (s.step === "start") {screen = { text: "Dealer desk\n1. Check stock\n2. Order status\n3. Call me back", end: false };s.step = "menu";} else if (s.step === "menu" && input === "1") {screen = { text: "Enter product code (e.g. 104):", end: false };s.step = "stock";} else if (s.step === "stock") {const qty = await stock.lookup(input); // keep this under a secondscreen = { text: `Product ${input}: ${qty} bags in stock.\nThank you.`, end: true };await sms.send(msisdn, `Stock for ${input}: ${qty} bags.`); // a record USSD cannot keep} else {screen = { text: "Sorry, try again by dialling the code.", end: true };}await sessions.set(session_id, s, { ttlSeconds: 300 });res.json(screen); // text of up to 182 characters, plus continue or end});
Keep state per session ID, answer every turn quickly and confirm important results by SMS.
Failure modes
Common mistakes with USSD
Menus that are too deep
Every extra level is another chance to time out. Keep to three or four screens, number the options and put the most common task first.
Asking for information users must look up
Long account numbers or IDs make people pause and lose the session. Ask for things they know, such as a mobile number, or send the details by SMS before the session.
A slow backend
The network will not wait for a slow database or a third-party API. Answer each turn in well under a second, and pre-load what the next screen needs.
Leaving users with no record
The screen vanishes when the session ends. Send an SMS or WhatsApp confirmation for anything that involves money, bookings or reference numbers.
Training customers to dial codes from strangers
Codes can change phone settings, as the call-forwarding scams showed. Never ask customers to dial a code with a number appended, and warn them not to follow such instructions from callers.
Design intent
Why does USSD matter?
For the many Indians who still use feature phones or have no reliable data, USSD is one of the few interactive channels that works everywhere, which is why payments, agriculture and microfinance services keep it alongside an IVR, a missed call service or, for smartphone users, WhatsApp Payments. For a business it is cheap to use and needs nothing installed, but it is unforgiving: every screen has to be understood and answered within the network's timeout, so menu design decides whether a USSD service works at all.
USSD FAQs
What is the difference between USSD and SMS?+
Does USSD work without internet?+
How does *99# work for UPI payments?+
Can a business send USSD messages to customers?+
Recommended practice
Best practices for USSD
- Write every screen in the user's language and test it on a basic feature phone, not an emulator.
- Fit each screen comfortably under 182 characters; shorter screens are faster to read before the timeout.
- Print the code and the first menu option on posters or packaging so users know what to expect.
- Log time per screen to find the step where sessions drop.