Skip to main content

Overview

This page documents breaking changes that may require code updates when upgrading django-allauth. Always review these changes before upgrading to a new major version.
Breaking changes can affect your application’s functionality. Test thoroughly in a staging environment before deploying to production.

Version 65.x

IP Address Detection (65.14.2)

Critical Security Change
What Changed: The default IP address detection no longer trusts X-Forwarded-For header. Impact: Rate limiting may not work correctly if not configured properly. Required Action: Configure IP detection for your deployment architecture.
settings.py
Migration Path:
  1. Identify your deployment architecture (direct, behind nginx, behind load balancer, etc.)
  2. Choose the appropriate configuration method
  3. Test rate limiting functionality
  4. Monitor for any IP detection issues

Version 64.x

Python 3.7 Support Dropped

What Changed: Python 3.8+ is now required. Impact: Applications running on Python 3.7 or earlier cannot use django-allauth 64.x+. Required Action: Upgrade to Python 3.8 or higher before upgrading django-allauth.

Template System Changes

What Changed: Introduction of element-based styling system. Impact: Custom templates may need updates to use the new system. Migration Path: Option 1: Adopt New System (Recommended)
settings.py
Create element overrides:
templates/allauth/elements/button.html
Option 2: Continue with Legacy Templates
settings.py

Version 63.x

Django 3.2 Support Dropped

What Changed: Django 4.2+ is now required. Impact: Projects on Django 3.2 or earlier need to upgrade Django first. Required Action: Upgrade to Django 4.2 LTS before upgrading django-allauth.

Version 62.x

Headless API Token Format

What Changed: JWT token structure and validation updated. Impact: Existing tokens may need to be refreshed. Migration Path:
  1. Update frontend to handle new token format
  2. Existing tokens remain valid until expiry
  3. New tokens use updated format

Version 60.x

MFA Models Changes

What Changed: MFA models were restructured for better extensibility. Impact: Custom MFA implementations need updates. Required Action: Run migrations and update custom MFA code.
If you have custom MFA authenticators:

Common Migration Patterns

Updating Settings

Old Approach (Pre-65.x):
New Approach (65.x+):
Old Approach (Pre-64.x):
templates/account/login.html
New Approach (64.x+):
templates/allauth/layouts/entrance.html
Or use element overrides:
templates/allauth/elements/button.html

Updating Code

Some adapter methods have been updated. Check if you override any:
Signal arguments remain backward compatible, but new parameters added:

Testing for Breaking Changes

Automated Detection

Add these tests to detect breaking changes:
tests/test_compatibility.py

Manual Testing

After upgrading, test these critical flows:
1

Authentication

  • Login with username
  • Login with email
  • Social login
  • MFA authentication
2

Rate Limiting

  • Trigger rate limits
  • Verify IP detection
  • Check rate limit messages
3

Templates

  • Check all authentication pages
  • Verify custom templates still work
  • Test responsive design
4

API (if applicable)

  • Test headless endpoints
  • Verify token format
  • Check CORS configuration

Version Compatibility Matrix

Getting Help

If you encounter issues with breaking changes:

Upgrade Guide

Step-by-step upgrade instructions

Changelog

Detailed version history

Stack Overflow

Ask the community

Issue Tracker

Report upgrade issues