eSIM Help

This Code Is No Longer Valid: Fix the iPhone eSIM Error Without Losing Your eSIM

What the iPhone alert "This code is no longer valid" means, how to check whether your eSIM is already installed, why you shouldn't delete it, and how to get and scan a new code. Checked Nov 6, 2026.

This Code Is No Longer Valid: Fix the iPhone eSIM Error Without Losing Your eSIM

Quick answer: what "eSIM cannot be added. This code is no longer valid" means

Your iPhone shows this alert when you scan an eSIM QR code or enter an activation code that has already been used or has expired. With many providers, a code works only once. So often the eSIM is already on your iPhone.

  • Check first: Settings > Cellular. If a new eSIM line is listed, the eSIM is installed. Turn the line on. You don't need to scan anything.
  • Don't delete it: with many providers, a deleted eSIM can't be added again with the same code.
  • No new line? Then you need a new code from the provider that sold you the eSIM. Apple can't issue one.

What the alert looks like on iPhone

In an Apple Support Community thread from June 2024, a user reports the alert as "eSIM cannot be added" with the text "This code is no longer valid. Contact your carrier for more information." It appears right after you scan the QR code or enter the code.

The reason is how eSIM codes work. Tello says each of its eSIM QR codes works only once, and the error means the code was already scanned or has expired (Tello). Orange Travel says "Each eSIM QR code can only be used once and is valid for installation on one single device" (Orange Travel). SpinTel says "most QR codes can only be used once" (SpinTel).

Why the code is no longer valid: common causes

"This code is no longer valid": causes and fixes (as of Nov 6, 2026)

CauseHow to tellWhat to do
eSIM already installedA new eSIM line shows in Settings > CellularDon't scan again. Turn the line on and use it.
QR code already used, then eSIM deletedNo matching line in Settings > Cellular, but the code was scanned beforeAsk your eSIM provider for a new code
Code used on another deviceThe eSIM is on a different phone or tabletA code is usually valid for one device only. Ask for a new one for this phone.
Code expiredThe code was never installed on any phone, but it is still rejectedAsk your eSIM provider for a new code

Sources: Tello, Orange Travel, SpinTel, eSIMFOX setup guide. eSIMFOX says the error usually means the eSIM is already on your phone or the QR code was already used.

Step 1: Check if the eSIM is already installed

Often the first scan worked, and only a second attempt shows the error. Check this before anything else:

  1. Open Settings and tap Cellular (Mobile Data in some regions).
  2. Look for a new eSIM line in the list of your SIMs.
  3. Tap the line and make sure Turn On This Line is enabled.
  4. For a travel eSIM: when you arrive, select it under Settings > Cellular > Cellular Data and turn on Data Roaming for that line.

An eSIMFOX eSIM is often named Travel, Mobile Data, Secondary, PLUS or eSIMFOX Travel (eSIMFOX setup guide). If you see it, you're done. eSIMFOX recommends keeping roaming off until you land. Data on the eSIM starts when you're at your destination with Data Roaming on for that line. Tello gives the same first step for its own eSIMs: if the line is listed in your cellular settings, switch it on, and no new scan is needed (Tello).

Choosing the data line is also covered by Apple: go to Settings > Cellular > Cellular Data and select the line you want to use (Apple). On iOS 26 and later, your iPhone may instead show a Turn On Travel eSIM notification when you arrive.

Step 2: Don't delete the eSIM

Some people delete the eSIM to scan the code again "cleanly." That usually makes it worse, because the code is already used. Apple's advice: "Don't erase an eSIM as a troubleshooting step unless directed to by your carrier." If you erase it, you'll need to contact your carrier to get a new one (Apple).

eSIMFOX says the same: don't delete the eSIM, and if you're unsure, contact eSIMFOX support before you try again (eSIMFOX).

Step 3: Check the internet connection and the basics

If no eSIM line shows up, make sure the setup itself can work. Apple says your iPhone must be connected to Wi-Fi or a hotspot and should run the latest iOS version it supports (Apple Support). Then Apple suggests:

  1. Turn Airplane Mode on and off.
  2. Open Settings > Cellular. If the number you're trying to activate is shown, turn that line off and back on.
  3. Restart your iPhone.
  4. Check for a carrier settings update: Settings > General > About, scroll to the eSIM section and tap the version number next to Carrier.

After each step, swipe down from the upper-right corner to open Control Center and check whether your carrier appears in the status bar. On iOS 18 or later, the Apple Support app can run extra diagnostics.

A travel eSIM from another provider also needs an iPhone that isn't carrier-locked. Go to Settings > General > About: "No SIM Restrictions" next to Carrier Lock means it's unlocked (Apple). If your iPhone says the eSIM is unsupported instead, read eSIM not compatible with this iPhone.

Step 4: Get a new code if no eSIM is installed

If there is no matching line under Settings > Cellular and the code keeps failing, only your eSIM provider can help. Apple says to contact your carrier to get a QR code (Apple).

  • eSIMFOX: send support your order number, a screenshot of your eSIM settings, a screenshot of your cellular settings and the error message on WhatsApp (eSIMFOX). Support is available 24/7 on WhatsApp (eSIMFOX Europe eSIM).
  • Other providers: many let you create a new code in your account. Tello, for example, says to log in, open My SIM and select Get eSIM to generate a new QR code (Tello). SpinTel asks you to contact its support for a new QR code (SpinTel).

Before you contact support, Apple suggests writing down the exact error message and having your IMEI or EID ready. You'll find both under Settings > General > About (Apple).

How to scan the new code the right way

Connect to Wi-Fi first. Then add the eSIM with the Camera app, as Apple describes it (Apple):

  1. Open the Camera app and scan the QR code. When the Cellular Plan Detected notification appears, tap it.
  2. Tap Continue at the bottom of the screen.
  3. Tap Add Cellular Plan.
  4. If you're asked for a confirmation code, enter the number your provider gave you.

If the QR code came by email and your iPhone runs iOS 17.4 or later, you can tap and hold the QR code in the email and then tap Add eSIM. If scanning doesn't work, enter the details by hand: Settings > Cellular (or Mobile Data) > Add Cellular Plan > Enter Details Manually (Apple). Copy the SM-DP+ address and activation code exactly as your provider sent them. More on that: What is an SM-DP+ address?

Scan each code only once. If the alert already says the code is no longer valid, go back to Step 1.

Getting a new iPhone soon? Install the eSIM on the phone you'll actually use. Orange Travel advises waiting to install until you have the new device, because a used QR code can't be moved to a second phone (Orange Travel).

Other iPhone eSIM errors

Sources

Frequently Asked Questions

What does "This code is no longer valid" mean on iPhone?
The eSIM QR code or activation code was already used or has expired. With many providers a code works only once. Often the eSIM is already installed on your iPhone, so check Settings > Cellular first.
Can I scan the same eSIM QR code twice?
Usually not. Tello and Orange Travel say each of their eSIM QR codes works only once, and SpinTel says most QR codes can be used only once. If you need to install the eSIM again, ask your provider for a new code.
How do I know if the eSIM is already installed?
Open Settings > Cellular and look for a new eSIM line. A travel eSIM from eSIMFOX is often named Travel, Mobile Data, Secondary, PLUS or eSIMFOX Travel. If it is there, turn the line on. You do not need to scan again.
Should I delete the eSIM and try again?
No. Apple says not to erase an eSIM as a troubleshooting step unless your carrier tells you to. If you erase it, you need a new eSIM from your carrier or provider. Contact support first.
I deleted the eSIM. What now?
The old code will most likely be rejected. Ask the provider that sold you the eSIM for a new code. eSIMFOX customers can send their order number, screenshots and the error message to support on WhatsApp.
Can I use the same eSIM code on a new iPhone?
Usually not once it has been used. Orange Travel says its QR code is valid for one device only and cannot be moved to another phone. Install the eSIM on the phone you will use, or ask your provider for a new code.
Do I need Wi-Fi to add an eSIM?
Apple says your iPhone needs to be connected to Wi-Fi or a hotspot to set up an eSIM. In some countries and regions, eSIM-only iPhone models can activate without Wi-Fi.
What is a confirmation code?
Some providers require an extra number to activate the eSIM. If your iPhone asks for a confirmation code while adding the eSIM, Apple says to enter the number your provider gave you.
The eSIM is installed, but I have no data. What should I do?
An eSIMFOX travel eSIM connects at your destination. Select it under Settings > Cellular > Cellular Data, turn on Data Roaming for that line, wait a few minutes and restart your iPhone if it still does not connect.

Stay connected on your next trip

Browse eSIM plans for 200+ destinations and activate in 60 seconds.