Summary
The raw data retention setting under Privacy → Regularly delete old data from the database can accept a number containing thousands formatting.
For example, a German user may enter:
1.460
intending this to mean 1460 days.
Matomo can instead interpret this value as 1 day. If automatic deletion is enabled, this can result in almost all historical raw data being permanently deleted.
This is particularly problematic because the entered value appears reasonable to users in locales where a dot is commonly used as the thousands separator, while the resulting retention period is dramatically different and destructive.
Expected behavior
The retention-period input should only allow an unformatted whole number of days.
Any number formatting or thousands separators should be removed/normalized before the value is saved.
For example:
1460 → 1460
1.460 → 1460
1,460 → 1460
The stored retention value should therefore always be an integer representing the intended number of days.
Ideally, the UI should also make it clear that this field represents a number of days and prevent formatting from being introduced in the first place.
Why this is important
This setting controls permanent deletion of historical raw tracking data. Incorrectly interpreting a formatted number can therefore cause irreversible data loss.
A user intending to retain approximately four years of data by entering 1.460 can unintentionally configure Matomo to retain only one day.
Because of the destructive nature of this setting, Matomo should normalize the value and ensure that number formatting cannot alter the intended retention period.
Summary
The raw data retention setting under Privacy → Regularly delete old data from the database can accept a number containing thousands formatting.
For example, a German user may enter:
1.460
intending this to mean 1460 days.
Matomo can instead interpret this value as 1 day. If automatic deletion is enabled, this can result in almost all historical raw data being permanently deleted.
This is particularly problematic because the entered value appears reasonable to users in locales where a dot is commonly used as the thousands separator, while the resulting retention period is dramatically different and destructive.
Expected behavior
The retention-period input should only allow an unformatted whole number of days.
Any number formatting or thousands separators should be removed/normalized before the value is saved.
For example:
1460 → 1460
1.460 → 1460
1,460 → 1460
The stored retention value should therefore always be an integer representing the intended number of days.
Ideally, the UI should also make it clear that this field represents a number of days and prevent formatting from being introduced in the first place.
Why this is important
This setting controls permanent deletion of historical raw tracking data. Incorrectly interpreting a formatted number can therefore cause irreversible data loss.
A user intending to retain approximately four years of data by entering 1.460 can unintentionally configure Matomo to retain only one day.
Because of the destructive nature of this setting, Matomo should normalize the value and ensure that number formatting cannot alter the intended retention period.