Skip to content

Apple 2FA SMS code rejected (“Invalid code”) when logging in via EAS CLI on Windows — code works in browser #3309

@Harsh1032

Description

@Harsh1032

Build/Submit details page URL

No response

Summary

When running eas build --platform ios --profile production, EAS prompts for Apple Developer login. Apple ID + password succeeds, but the 6-digit 2FA code sent via SMS is consistently rejected as “Invalid code”. The same account/code works when signing in via the Apple website/browser. This started happening since last Thursday previously working for months with the same account and EAS workflow.

Managed or bare?

Managed

Environment

expo-env-info 2.0.8 environment info:
System:
OS: Windows 11 10.0.26200
Binaries:
Node: 22.14.0
npm: 10.9.2
IDEs:
Android Studio: AI-243.24978.46.2431.13208083
npmPackages:
expo: ^54.0.7 => 54.0.21
expo-router: ~6.0.4 => 6.0.14
expo-updates: ~29.0.10 => 29.0.12
react: 19.1.0
react-dom: 19.1.0
react-native: 0.81.4
react-native-web: 0.21.2
Expo Workflow: managed

Error output

EXPO_DEBUG=true
Command: eas build --platform ios --profile production

... Apple ID accepted ...
... password accepted ...
Two-factor Authentication enabled
Please enter the 6 digit code you received at +971…10
Entered correct code
✖ Invalid code
(re-prompts for 2FA)

Reproducible demo or steps to reproduce from a blank project

Repro steps (blank project):

  1. npx create-expo-app@latest repro-apple-2fa
  2. cd repro-apple-2fa
  3. eas init
  4. eas build --platform ios --profile production
  5. When prompted, log in to Apple Developer account
  6. Enter Apple ID + password (works)
  7. Enter 6-digit 2FA code received via SMS (rejected with “Invalid code”)

Notes:

  • The same Apple ID/2FA code works when signing in via Apple website/browser.
  • This started since last Thursday; we have already completed ~94 EAS iOS builds successfully before this regression using the same client-owned Apple Developer Organization account.

Metadata

Metadata

Assignees

Labels

needs reviewIssue is ready to be reviewed by a maintainer

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions