An aside to the technical question of how to migrate profiles to older versions:
DO NOT DOWNGRADE FIREFOX BELOW 131.0.2 OR ESR 128.3.1, 115.16.1
I feel that given this recent vulnerability, it is important to make this notice.
Otherwise:
For migrating profiles between the same major version, Mozilla provides a guide for full profile migration. This also works with forwards compatibility. I generally wouldn't try to go backwards however as many new major versions change the data format and contents of your profiles, which older versions have no idea how to interpret.
For downgrading, it's best to export bookmarks, go through your important addons and backup the settings for each one that needs configuration, and take note of anything you're previously modified in about:config to your preference. Perhaps take screenshots of your tab bar and overflow menu as well so you can recustomize them to your liking easily on the downgraded version.