diff --git a/src/marshmallow/utils.py b/src/marshmallow/utils.py
index 113906d6..87bba69c 100755
--- a/src/marshmallow/utils.py
+++ b/src/marshmallow/utils.py
@@ -285,6 +285,9 @@ def from_iso(datestring, use_dateutil=True):
         # Strip off timezone info.
         if '.' in datestring:
             # datestring contains microseconds
+            (dt_nomstz, mstz) = datestring.split('.')
+            ms_notz = mstz[:len(mstz) - len(mstz.lstrip('0123456789'))]
+            datestring = '.'.join((dt_nomstz, ms_notz))
             return datetime.datetime.strptime(datestring[:26], '%Y-%m-%dT%H:%M:%S.%f')
         return datetime.datetime.strptime(datestring[:19], '%Y-%m-%dT%H:%M:%S')
 

ISO8601 DateTimes ending with Z considered not valid in 2.19.4
Probably related to #1247 and #1234 - in marshmallow `2.19.4`, with `python-dateutil` _not_ installed, it seems that loading a datetime in ISO8601 that ends in `Z` (UTC time) results in an error:

```python
class Foo(Schema):
    date = DateTime(required=True)


foo_schema = Foo(strict=True)

a_date_with_z = '2019-06-17T00:57:41.000Z'
foo_schema.load({'date': a_date_with_z})
```

```
marshmallow.exceptions.ValidationError: {'date': ['Not a valid datetime.']}
```

Digging a bit deeper, it seems [`from_iso_datetime`](https://github.com/marshmallow-code/marshmallow/blob/dev/src/marshmallow/utils.py#L213-L215) is failing with a `unconverted data remains: Z` - my understanding of the spec is rather limited, but it seems that they are indeed valid ISO8601 dates (and in `marshmallow==2.19.3` and earlier, the previous snippet seems to work without raising validation errors).

diff --git a/tests/test_utils.py b/tests/test_utils.py
index a5d68621..dff83171 100644
--- a/tests/test_utils.py
+++ b/tests/test_utils.py
@@ -200,6 +200,15 @@ def test_from_iso_datetime(use_dateutil, timezone):
     assert type(result) == dt.datetime
     assert_datetime_equal(result, d)
 
+    # Test with 3-digit only microseconds
+    # Regression test for https://github.com/marshmallow-code/marshmallow/issues/1251
+    d = dt.datetime.now(tz=timezone).replace(microsecond=123000)
+    formatted = d.isoformat()
+    formatted = formatted[:23] + formatted[26:]
+    result = utils.from_iso(formatted, use_dateutil=use_dateutil)
+    assert type(result) == dt.datetime
+    assert_datetime_equal(result, d)
+
 def test_from_iso_with_tz():
     d = central.localize(dt.datetime.now())
     formatted = d.isoformat()

pip install -e .[dev]
parse_log_pytest
requirements.txt
apt-get update apt-get install -y gcc
3.9
docs/requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
alabaster==0.7.12
babel==2.17.0
cachetools==5.5.2
certifi==2025.1.31
chardet==5.2.0
charset-normalizer==3.4.1
colorama==0.4.6
distlib==0.3.9
docutils==0.21.2
entrypoints==0.3
exceptiongroup==1.2.2
filelock==3.18.0
flake8==3.7.4
idna==3.10
imagesize==1.4.1
iniconfig==2.1.0
Jinja2==3.1.6
MarkupSafe==3.0.2
-e git+https://github.com/marshmallow-code/marshmallow.git@b063a103ae5222a5953cd7453a1eb0d161dc5b52#egg=marshmallow
mccabe==0.6.1
packaging==24.2
platformdirs==4.3.7
pluggy==1.5.0
pycodestyle==2.5.0
pyflakes==2.1.1
Pygments==2.19.1
pyproject-api==1.9.0
pytest==8.3.5
python-dateutil==2.9.0.post0
pytz==2025.2
requests==2.32.3
simplejson==3.20.1
six==1.17.0
snowballstemmer==2.2.0
Sphinx==1.8.1
sphinx-issues==1.1.0
sphinx-version-warning==1.0.2
sphinxcontrib-serializinghtml==2.0.0
sphinxcontrib-websupport==1.2.4
tomli==2.2.1
tox==4.25.0
typing_extensions==4.13.0
urllib3==2.3.0
virtualenv==20.29.3

name: marshmallow
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=25.0=py39h06a4308_0
  - python=3.9.21=he870216_1
  - readline=8.2=h5eee18b_0
  - setuptools=75.8.0=py39h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - tzdata=2025a=h04d1e81_0
  - wheel=0.45.1=py39h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - alabaster==0.7.12
      - babel==2.17.0
      - cachetools==5.5.2
      - certifi==2025.1.31
      - chardet==5.2.0
      - charset-normalizer==3.4.1
      - colorama==0.4.6
      - distlib==0.3.9
      - docutils==0.21.2
      - entrypoints==0.3
      - exceptiongroup==1.2.2
      - filelock==3.18.0
      - flake8==3.7.4
      - idna==3.10
      - imagesize==1.4.1
      - iniconfig==2.1.0
      - jinja2==3.1.6
      - markupsafe==3.0.2
      - mccabe==0.6.1
      - packaging==24.2
      - platformdirs==4.3.7
      - pluggy==1.5.0
      - pycodestyle==2.5.0
      - pyflakes==2.1.1
      - pygments==2.19.1
      - pyproject-api==1.9.0
      - pytest==8.3.5
      - python-dateutil==2.9.0.post0
      - pytz==2025.2
      - requests==2.32.3
      - simplejson==3.20.1
      - six==1.17.0
      - snowballstemmer==2.2.0
      - sphinx==1.8.1
      - sphinx-issues==1.1.0
      - sphinx-version-warning==1.0.2
      - sphinxcontrib-serializinghtml==2.0.0
      - sphinxcontrib-websupport==1.2.4
      - tomli==2.2.1
      - tox==4.25.0
      - typing-extensions==4.13.0
      - urllib3==2.3.0
      - virtualenv==20.29.3
prefix: /opt/conda/envs/marshmallow

tests/test_utils.py::test_from_iso_datetime[timezone1-False]
tests/test_utils.py::test_missing_singleton_copy tests/test_utils.py::test_to_marshallable_type tests/test_utils.py::test_to_marshallable_type_none tests/test_utils.py::test_to_marshallable_type_with_namedtuple tests/test_utils.py::test_get_value_from_object[obj0] tests/test_utils.py::test_get_value_from_object[obj1] tests/test_utils.py::test_get_value_from_object[obj2] tests/test_utils.py::test_get_value_from_namedtuple_with_default tests/test_utils.py::test_get_value_for_nested_object tests/test_utils.py::test_get_value_from_dict tests/test_utils.py::test_get_value tests/test_utils.py::test_set_value tests/test_utils.py::test_is_keyed_tuple tests/test_utils.py::test_to_marshallable_type_list tests/test_utils.py::test_to_marshallable_type_generator tests/test_utils.py::test_marshallable tests/test_utils.py::test_is_collection tests/test_utils.py::test_rfcformat_gmt_naive tests/test_utils.py::test_rfcformat_central tests/test_utils.py::test_rfcformat_central_localized tests/test_utils.py::test_isoformat tests/test_utils.py::test_isoformat_tzaware tests/test_utils.py::test_isoformat_localtime tests/test_utils.py::test_from_datestring tests/test_utils.py::test_from_rfc[True] tests/test_utils.py::test_from_rfc[False] tests/test_utils.py::test_from_iso_datetime[None-True] tests/test_utils.py::test_from_iso_datetime[None-False] tests/test_utils.py::test_from_iso_datetime[timezone1-True] tests/test_utils.py::test_from_iso_with_tz tests/test_utils.py::test_from_iso_time_with_microseconds[True] tests/test_utils.py::test_from_iso_time_with_microseconds[False] tests/test_utils.py::test_from_iso_time_without_microseconds[True] tests/test_utils.py::test_from_iso_time_without_microseconds[False] tests/test_utils.py::test_from_iso_date[True] tests/test_utils.py::test_from_iso_date[False] tests/test_utils.py::test_get_func_args
src/marshmallow/utils.py
src/marshmallow/utils.py