In principle, all records of credit investigation will be kept for five years. However, if there is any bad credit record, such as overdue, and it has been delayed, then this record will accompany you for life, so you should develop good repayment habits at ordinary times.
For example, normal credit records will always remain in the credit information, but new records will gradually overwrite the old records. Banks and licensed consumer finance companies mainly refer to customers' credit information in the last two years when handling credit business, so they often only make inquiries in the last two years.