INVALID_OR_NULL_FOR_RESTRICTED_PICKLIST:bad value for restricted picklist field: US:CountryCode --
The short answer: the field is a restricted picklist, so it only
accepts values from its defined value set. Your file contains something else — usually an
abbreviation (US instead of United States), a legacy label from
another system, or a blank that arrives as text. Either translate the values in your file to
the exact values the field accepts, or add the missing value to the field in Setup.
Find the values the field actually accepts
Before changing anything in your file, get the authoritative list. In Salesforce: Setup → Object Manager → your object → Fields & Relationships → the field named in the error → scroll to Values.
Two things on that screen decide whether you are even seeing the whole problem:
- "Restrict picklist to the values defined in the value set" — if this is ticked, Salesforce refuses anything outside the list. That checkbox is why you got this error rather than a silently created value.
- Active vs. inactive values — an inactive value still appears on existing records but cannot be written by an import. A value that "obviously exists" and still fails is very often an inactive one.
The four causes, in the order you should check them
1. The value simply is not in the list
The common case, and the boring one. Your source system says Prospect; Salesforce
says Open - Not Contacted. Nothing is broken — the two systems just have different
vocabularies, and something has to translate between them.
2. It is a State or Country picklist, and it wants the code
If your org has State and Country/Territory picklists enabled, the API fields are
BillingCountryCode and BillingStateCode, and they take the ISO
code, not the name and not your own abbreviation. US is valid.
USA is not. United States is valid in the BillingCountry
text field but not in the …CountryCode field. Loading the wrong one of the pair is
one of the most common versions of this error.
3. The value exists, but not for that record type
Picklist values are assigned per record type. If the value is in the master value set but is not available on the record type you are loading into, the import is rejected with the same message — and the value is sitting right there in Setup, which makes this one genuinely maddening. Check Object Manager → Record Types → your record type → the field, and confirm the value is in the selected list.
4. Whitespace, casing, and multi-select separators
A trailing space ("Open ") makes a value a different string. Multi-select picklists
expect selections joined by semicolons with no spaces — Email;Phone, not
Email, Phone — and each selection is validated separately. Case alone is usually
forgiven on insert, but whitespace never is.
Fix it: change the field, or change the file
Option A — add the value to Salesforce
Right when the value is genuinely legitimate and missing. Setup → the field → New
under Values, then assign it to the relevant record types. Do not reach for the other lever on
that page — unticking "restrict picklist" removes the guardrail for everyone, forever, so that a
single import can pass. That is how orgs end up with Calfornia in production.
Option B — translate the values in your file
Usually the right fix, because your source system is not going to stop saying US.
The mechanical version is a find-and-replace per value, or a VLOOKUP column that maps each source
value to an accepted one, before you load:
US → United States
U.S.A. → United States
UK → United Kingdom
Prospect → Open - Not Contacted
Qualified → Working - Contacted
The trap is that you cannot see the full list of values you need to map without scanning the whole file. Fixing the three values in the error log, re-running, and discovering four more is the loop that turns a ten-minute import into an afternoon.
Get every bad value in one pass, before you load
Whatever tool you use, the goal is the same: list the distinct values your file uses for that column, compare that set against the field's accepted values, and translate the gaps — all before a single record is written.
This is what INQUA's import tool
is built to do. When the target field comes from your org, it captures the field's accepted
picklist values with it, so preview flags every violating cell before anything is written —
not after Salesforce rejects the job. Its Map values editor then lists every
distinct value in your source column next to a dropdown of the accepted values, so you fix the
whole set in one screen. If the translations are obvious (US → United
States), one click asks the AI to propose them and you approve or correct each one.
It works on a plain CSV or Excel file with no Salesforce connection at all, and it never deletes records — the direct load is an insert or an External-ID upsert, previewed and confirmed.
After the fix
Re-run the load and confirm the count. If you still see rejections, check that they are the same
error: REQUIRED_FIELD_MISSING and
type-conversion failures often
surface only once the picklist problem stops masking them.