diff -r a21c8b554d43 django/contrib/gis/db/backends/spatialite/base.py
--- a/django/contrib/gis/db/backends/spatialite/base.py	Sun Sep 04 22:51:53 2011 +0000
+++ b/django/contrib/gis/db/backends/spatialite/base.py	Fri Sep 09 12:47:16 2011 -0700
@@ -2,16 +2,16 @@
 from django.conf import settings
 
 from django.core.exceptions import ImproperlyConfigured
-from django.db.backends.sqlite3.base import *
 from django.db.backends.sqlite3.base import (
-    _sqlite_extract, _sqlite_date_trunc, _sqlite_regexp,
-    DatabaseWrapper as SqliteDatabaseWrapper)
+    _sqlite_extract, _sqlite_date_trunc, _sqlite_regexp, _sqlite_format_dtdelta,
+    connection_created, Database, DatabaseWrapper as SQLiteDatabaseWrapper,
+    SQLiteCursorWrapper)
 from django.contrib.gis.db.backends.spatialite.client import SpatiaLiteClient
 from django.contrib.gis.db.backends.spatialite.creation import SpatiaLiteCreation
 from django.contrib.gis.db.backends.spatialite.introspection import SpatiaLiteIntrospection
 from django.contrib.gis.db.backends.spatialite.operations import SpatiaLiteOperations
 
-class DatabaseWrapper(SqliteDatabaseWrapper):
+class DatabaseWrapper(SQLiteDatabaseWrapper):
     def __init__(self, *args, **kwargs):
         # Before we get too far, make sure pysqlite 2.5+ is installed.
         if Database.version_info < (2, 5, 0):
@@ -52,6 +52,7 @@
             self.connection.create_function("django_extract", 2, _sqlite_extract)
             self.connection.create_function("django_date_trunc", 2, _sqlite_date_trunc)
             self.connection.create_function("regexp", 2, _sqlite_regexp)
+            self.connection.create_function("django_format_dtdelta", 5, _sqlite_format_dtdelta)
             connection_created.send(sender=self.__class__, connection=self)
 
             ## From here on, customized for GeoDjango ##
diff -r a21c8b554d43 django/contrib/gis/db/backends/spatialite/compiler.py
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/django/contrib/gis/db/backends/spatialite/compiler.py	Fri Sep 09 12:47:16 2011 -0700
@@ -0,0 +1,32 @@
+from django.db.backends.util import typecast_timestamp
+from django.db.models.sql import compiler
+from django.db.models.sql.constants import MULTI
+from django.contrib.gis.db.models.sql.compiler import GeoSQLCompiler as BaseGeoSQLCompiler
+
+SQLCompiler = compiler.SQLCompiler
+
+class GeoSQLCompiler(BaseGeoSQLCompiler, SQLCompiler):
+    pass
+
+class SQLInsertCompiler(compiler.SQLInsertCompiler, GeoSQLCompiler):
+    pass
+
+class SQLDeleteCompiler(compiler.SQLDeleteCompiler, GeoSQLCompiler):
+    pass
+
+class SQLUpdateCompiler(compiler.SQLUpdateCompiler, GeoSQLCompiler):
+    pass
+
+class SQLAggregateCompiler(compiler.SQLAggregateCompiler, GeoSQLCompiler):
+    pass
+
+class SQLDateCompiler(compiler.SQLDateCompiler, GeoSQLCompiler):
+    """
+    This is overridden for GeoDjango to properly cast date columns, see #16757.
+    """
+    def results_iter(self):
+        offset = len(self.query.extra_select)
+        for rows in self.execute_sql(MULTI):
+            for row in rows:
+                date = typecast_timestamp(str(row[offset]))
+                yield date
diff -r a21c8b554d43 django/contrib/gis/db/backends/spatialite/operations.py
--- a/django/contrib/gis/db/backends/spatialite/operations.py	Sun Sep 04 22:51:53 2011 +0000
+++ b/django/contrib/gis/db/backends/spatialite/operations.py	Fri Sep 09 12:47:16 2011 -0700
@@ -48,7 +48,7 @@
     return (SpatiaLiteDistance(operator),)
 
 class SpatiaLiteOperations(DatabaseOperations, BaseSpatialOperations):
-    compiler_module = 'django.contrib.gis.db.models.sql.compiler'
+    compiler_module = 'django.contrib.gis.db.backends.spatialite.compiler'
     name = 'spatialite'
     spatialite = True
     version_regex = re.compile(r'^(?P<major>\d)\.(?P<minor1>\d)\.(?P<minor2>\d+)')
diff -r a21c8b554d43 django/contrib/gis/tests/geoapp/models.py
--- a/django/contrib/gis/tests/geoapp/models.py	Sun Sep 04 22:51:53 2011 +0000
+++ b/django/contrib/gis/tests/geoapp/models.py	Fri Sep 09 12:47:16 2011 -0700
@@ -19,6 +19,7 @@
 # This is an inherited model from City
 class PennsylvaniaCity(City):
     county = models.CharField(max_length=30)
+    founded = models.DateTimeField(null=True)
     objects = models.GeoManager() # TODO: This should be implicitly inherited.
 
 class State(models.Model):
diff -r a21c8b554d43 django/contrib/gis/tests/geoapp/test_regress.py
--- a/django/contrib/gis/tests/geoapp/test_regress.py	Sun Sep 04 22:51:53 2011 +0000
+++ b/django/contrib/gis/tests/geoapp/test_regress.py	Fri Sep 09 12:47:16 2011 -0700
@@ -1,9 +1,10 @@
-import unittest
+from datetime import datetime
 from django.contrib.gis.tests.utils import no_mysql, no_spatialite
 from django.contrib.gis.shortcuts import render_to_kmz
-from models import City
+from django.test import TestCase
+from models import City, PennsylvaniaCity
 
-class GeoRegressionTests(unittest.TestCase):
+class GeoRegressionTests(TestCase):
 
     def test01_update(self):
         "Testing GeoQuerySet.update(), see #10411."
@@ -35,3 +36,10 @@
         extent = City.objects.filter(name='Pueblo').extent()
         for ref_val, val in zip(ref_ext, extent):
             self.assertAlmostEqual(ref_val, val, 4)
+
+    def test04_unicode_date(self):
+        "Testing dates are converted properly, even on SpatiaLite, see #16408."
+        founded = datetime(1857, 5, 23)
+        mansfield = PennsylvaniaCity.objects.create(name='Mansfield', county='Tioga', point='POINT(-77.071445 41.823881)',
+                                                    founded=founded)
+        self.assertEqual(founded, PennsylvaniaCity.objects.dates('founded', 'day')[0])
