pandas 3 String Dtype in Python

From the Pandas cheat sheet ยท Data Types ยท verified Aug 2026

pandas 3 String Dtype

Use the default dedicated string dtype safely.

python
names = pd.Series(["Ana", "Ben", None], dtype="str")
๐Ÿ“Œ pandas 3 infers str instead of object
๐Ÿ” Missing strings use NaN in the default str dtype
โš ๏ธ Non-string assignment raises TypeError
๐ŸŽฏ Use is_string_dtype for compatibility checks
stringsdtypepandas-3

Continue with Pandas

Save the full cheat sheet or work through every related task.

More Python tasks

Back to the full Pandas cheat sheet